Kaydet (Commit) 0378fa5f authored tarafından Laurent BP's avatar Laurent BP Kaydeden (comit) Heiko Tietze

Writer templates: built from XML code

Maintaining XML code is easier if we need to change a font
(name or size). See tdf#114749

Change-Id: I1c1e5951c24863be717aef3dd22d533f5fd23a4f
Reviewed-on: https://gerrit.libreoffice.org/58787
Tested-by: Jenkins
Reviewed-by: 's avatarHeiko Tietze <tietze.heiko@gmail.com>
Tested-by: 's avatarHeiko Tietze <tietze.heiko@gmail.com>
üst f61af646
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_CustomTarget_CustomTarget,extras/source/templates/styles))
extras_TEMPLATES_STYLES := \
Default \
Modern \
extras_STYLES_XMLFILES := \
Default/META-INF/manifest.xml \
Default/meta.xml \
Default/styles.xml \
Default/Thumbnails/thumbnail.png \
Modern/META-INF/manifest.xml \
Modern/meta.xml \
Modern/styles.xml \
Modern/Thumbnails/thumbnail.png \
extras_TPLSTYLES_MIMETYPEFILES := $(foreach atexts,$(extras_TEMPLATES_STYLES),$(atexts)/mimetype)
ifneq ($(sort $(foreach file,$(extras_STYLES_XMLFILES),$(wordlist 1, 1, $(subst /, ,$(file))))),$(sort $(extras_TEMPLATES_STYLES)))
$(call gb_Output_error,defined template text do not match existing directories)
endif
$(call gb_CustomTarget_get_target,extras/source/templates/styles) : \
$(foreach atexts,$(extras_TEMPLATES_STYLES),$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)/$(atexts).ott)
$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)/%/mimetype : $(SRCDIR)/extras/source/templates/styles/%/mimetype
$(call gb_Output_announce,$*/mimetype,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)/%.jpg : $(SRCDIR)/extras/source/templates/styles/%.jpg
$(call gb_Output_announce,$*.jpg,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)/%.png : $(SRCDIR)/extras/source/templates/styles/%.png
$(call gb_Output_announce,$*.png,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)/%.rdf : $(SRCDIR)/extras/source/templates/styles/%.rdf
$(call gb_Output_announce,$*.rdf,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)/%.svg : $(SRCDIR)/extras/source/templates/styles/%.svg
$(call gb_Output_announce,$*.svg,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)/%.svm : $(SRCDIR)/extras/source/templates/styles/%.svm
$(call gb_Output_announce,$*.svm,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)/%.xml : $(SRCDIR)/extras/source/templates/styles/%.xml \
| $(call gb_ExternalExecutable_get_dependencies,xsltproc)
$(call gb_Output_announce,$*.xml,$(true),XSL,1)
$(call gb_ExternalExecutable_get_command,xsltproc) --nonet -o $@ $(SRCDIR)/extras/util/compact.xsl $<
$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)/%.ott :
$(call gb_Output_announce,$*.ott,$(true),ZIP,2)
$(call gb_Helper_abbreviate_dirs,\
cd $(EXTRAS_STYLES_DIR) && \
zip -qrX --filesync --must-match $@ $(EXTRAS_STYLES_FILES) \
)
define extras_Tplstyles_make_file_deps
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : $(SRCDIR)/$(1)/$(2) \
| $(dir $(call gb_CustomTarget_get_workdir,$(1))/$(2)).dir
endef
define extras_Tplstyles_make_zip_deps
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
$(addprefix $(call gb_CustomTarget_get_workdir,$(1))/,$(filter $(3)/%,$(extras_TPLSTYLES_MIMETYPEFILES) $(extras_STYLES_XMLFILES))) \
| $(dir $(call gb_CustomTarget_get_workdir,$(1))/$(2)).dir
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
EXTRAS_STYLES_FILES := $(foreach file,$(filter $(3)/%,$(extras_TPLSTYLES_MIMETYPEFILES) $(extras_STYLES_XMLFILES)),$(subst $(3)/,,$(file)))
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
EXTRAS_STYLES_DIR := $(call gb_CustomTarget_get_workdir,$(1))/$(3)
endef
$(eval $(foreach file,$(extras_TPLSTYLES_MIMETYPEFILES) $(extras_STYLES_XMLFILES),\
$(call extras_Tplstyles_make_zip_deps,extras/source/templates/styles,$(file)) \
))
$(eval $(foreach atexts,$(extras_TEMPLATES_STYLES),\
$(call extras_Tplstyles_make_zip_deps,extras/source/templates/styles,$(atexts).ott,$(atexts)) \
))
# vim: set noet sw=4 ts=4:
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_CustomTarget_CustomTarget,extras/source/templates/officorr))
extras_TEMPLATES_OFFICORR := \
Modern_business_letter_sans_serif \
Modern_business_letter_serif \
extras_OFFICORR_XMLFILES := \
Modern_business_letter_sans_serif/content.xml \
Modern_business_letter_sans_serif/manifest.rdf \
Modern_business_letter_sans_serif/META-INF/manifest.xml \
Modern_business_letter_sans_serif/meta.xml \
Modern_business_letter_sans_serif/styles.xml \
Modern_business_letter_sans_serif/Thumbnails/thumbnail.png \
Modern_business_letter_serif/content.xml \
Modern_business_letter_serif/manifest.rdf \
Modern_business_letter_serif/META-INF/manifest.xml \
Modern_business_letter_serif/meta.xml \
Modern_business_letter_serif/styles.xml \
Modern_business_letter_serif/Thumbnails/thumbnail.png \
extras_TPLOFFICORR_MIMETYPEFILES := $(foreach atexts,$(extras_TEMPLATES_OFFICORR),$(atexts)/mimetype)
ifneq ($(sort $(foreach file,$(extras_OFFICORR_XMLFILES),$(wordlist 1, 1, $(subst /, ,$(file))))),$(sort $(extras_TEMPLATES_OFFICORR)))
$(call gb_Output_error,defined template text do not match existing directories)
endif
$(call gb_CustomTarget_get_target,extras/source/templates/officorr) : \
$(foreach atexts,$(extras_TEMPLATES_OFFICORR),$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)/$(atexts).ott)
$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)/%/mimetype : $(SRCDIR)/extras/source/templates/officorr/%/mimetype
$(call gb_Output_announce,$*/mimetype,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)/%.jpg : $(SRCDIR)/extras/source/templates/officorr/%.jpg
$(call gb_Output_announce,$*.jpg,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)/%.rdf : $(SRCDIR)/extras/source/templates/officorr/%.rdf
$(call gb_Output_announce,$*.rdf,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)/%.png : $(SRCDIR)/extras/source/templates/officorr/%.png
$(call gb_Output_announce,$*.png,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)/%.svg : $(SRCDIR)/extras/source/templates/officorr/%.svg
$(call gb_Output_announce,$*.svg,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)/%.svm : $(SRCDIR)/extras/source/templates/officorr/%.svm
$(call gb_Output_announce,$*.svm,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)/%.xml : $(SRCDIR)/extras/source/templates/officorr/%.xml \
| $(call gb_ExternalExecutable_get_dependencies,xsltproc)
$(call gb_Output_announce,$*.xml,$(true),XSL,1)
$(call gb_ExternalExecutable_get_command,xsltproc) --nonet -o $@ $(SRCDIR)/extras/util/compact.xsl $<
$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)/%.ott :
$(call gb_Output_announce,$*.ott,$(true),ZIP,2)
$(call gb_Helper_abbreviate_dirs,\
cd $(EXTRAS_OFFICORR_DIR) && \
zip -qrX --filesync --must-match $@ $(EXTRAS_OFFICORR_FILES) \
)
define extras_Tplofficorr_make_file_deps
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : $(SRCDIR)/$(1)/$(2) \
| $(dir $(call gb_CustomTarget_get_workdir,$(1))/$(2)).dir
endef
define extras_Tplofficorr_make_zip_deps
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
$(addprefix $(call gb_CustomTarget_get_workdir,$(1))/,$(filter $(3)/%,$(extras_TPLOFFICORR_MIMETYPEFILES) $(extras_OFFICORR_XMLFILES))) \
| $(dir $(call gb_CustomTarget_get_workdir,$(1))/$(2)).dir
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
EXTRAS_OFFICORR_FILES := $(foreach file,$(filter $(3)/%,$(extras_TPLOFFICORR_MIMETYPEFILES) $(extras_OFFICORR_XMLFILES)),$(subst $(3)/,,$(file)))
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
EXTRAS_OFFICORR_DIR := $(call gb_CustomTarget_get_workdir,$(1))/$(3)
endef
$(eval $(foreach file,$(extras_TPLOFFICORR_MIMETYPEFILES) $(extras_OFFICORR_XMLFILES),\
$(call extras_Tplofficorr_make_zip_deps,extras/source/templates/officorr,$(file)) \
))
$(eval $(foreach atexts,$(extras_TEMPLATES_OFFICORR),\
$(call extras_Tplofficorr_make_zip_deps,extras/source/templates/officorr,$(atexts).ott,$(atexts)) \
))
# vim: set noet sw=4 ts=4:
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_CustomTarget_CustomTarget,extras/source/templates/offimisc))
extras_TEMPLATES_OFFIMISC := \
Businesscard-with-logo \
extras_OFFIMISC_XMLFILES := \
Businesscard-with-logo/content.xml \
Businesscard-with-logo/manifest.rdf \
Businesscard-with-logo/META-INF/manifest.xml \
Businesscard-with-logo/meta.xml \
Businesscard-with-logo/Pictures/10000201000001F4000000A0108F3F06.png \
Businesscard-with-logo/settings.xml \
Businesscard-with-logo/styles.xml \
Businesscard-with-logo/Thumbnails/thumbnail.png \
extras_TPLOFFIMISC_MIMETYPEFILES := $(foreach atexts,$(extras_TEMPLATES_OFFIMISC),$(atexts)/mimetype)
ifneq ($(sort $(foreach file,$(extras_OFFIMISC_XMLFILES),$(wordlist 1, 1, $(subst /, ,$(file))))),$(sort $(extras_TEMPLATES_OFFIMISC)))
$(call gb_Output_error,defined template text do not match existing directories)
endif
$(call gb_CustomTarget_get_target,extras/source/templates/offimisc) : \
$(foreach atexts,$(extras_TEMPLATES_OFFIMISC),$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)/$(atexts).ott)
$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)/%/mimetype : $(SRCDIR)/extras/source/templates/offimisc/%/mimetype
$(call gb_Output_announce,$*/mimetype,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)/%.jpg : $(SRCDIR)/extras/source/templates/offimisc/%.jpg
$(call gb_Output_announce,$*.jpg,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)/%.png : $(SRCDIR)/extras/source/templates/offimisc/%.png
$(call gb_Output_announce,$*.png,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)/%.rdf : $(SRCDIR)/extras/source/templates/offimisc/%.rdf
$(call gb_Output_announce,$*.rdf,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)/%.svg : $(SRCDIR)/extras/source/templates/offimisc/%.svg
$(call gb_Output_announce,$*.svg,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)/%.svm : $(SRCDIR)/extras/source/templates/offimisc/%.svm
$(call gb_Output_announce,$*.svm,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)/%.xml : $(SRCDIR)/extras/source/templates/offimisc/%.xml \
| $(call gb_ExternalExecutable_get_dependencies,xsltproc)
$(call gb_Output_announce,$*.xml,$(true),XSL,1)
$(call gb_ExternalExecutable_get_command,xsltproc) --nonet -o $@ $(SRCDIR)/extras/util/compact.xsl $<
$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)/%.ott :
$(call gb_Output_announce,$*.ott,$(true),ZIP,2)
$(call gb_Helper_abbreviate_dirs,\
cd $(EXTRAS_OFFIMISC_DIR) && \
zip -qrX --filesync --must-match $@ $(EXTRAS_OFFIMISC_FILES) \
)
define extras_Tploffimisc_make_file_deps
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : $(SRCDIR)/$(1)/$(2) \
| $(dir $(call gb_CustomTarget_get_workdir,$(1))/$(2)).dir
endef
define extras_Tploffimisc_make_zip_deps
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
$(addprefix $(call gb_CustomTarget_get_workdir,$(1))/,$(filter $(3)/%,$(extras_TPLOFFIMISC_MIMETYPEFILES) $(extras_OFFIMISC_XMLFILES))) \
| $(dir $(call gb_CustomTarget_get_workdir,$(1))/$(2)).dir
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
EXTRAS_OFFIMISC_FILES := $(foreach file,$(filter $(3)/%,$(extras_TPLOFFIMISC_MIMETYPEFILES) $(extras_OFFIMISC_XMLFILES)),$(subst $(3)/,,$(file)))
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
EXTRAS_OFFIMISC_DIR := $(call gb_CustomTarget_get_workdir,$(1))/$(3)
endef
$(eval $(foreach file,$(extras_TPLOFFIMISC_MIMETYPEFILES) $(extras_OFFIMISC_XMLFILES),\
$(call extras_Tploffimisc_make_zip_deps,extras/source/templates/offimisc,$(file)) \
))
$(eval $(foreach atexts,$(extras_TEMPLATES_OFFIMISC),\
$(call extras_Tploffimisc_make_zip_deps,extras/source/templates/offimisc,$(atexts).ott,$(atexts)) \
))
# vim: set noet sw=4 ts=4:
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_CustomTarget_CustomTarget,extras/source/templates/personal))
extras_TEMPLATES_PERSONAL := \
CV \
Resume1page \
extras_PERSONAL_XMLFILES := \
CV/content.xml \
CV/manifest.rdf \
CV/META-INF/manifest.xml \
CV/meta.xml \
CV/styles.xml \
CV/Thumbnails/thumbnail.png \
Resume1page/content.xml \
Resume1page/manifest.rdf \
Resume1page/META-INF/manifest.xml \
Resume1page/meta.xml \
Resume1page/styles.xml \
Resume1page/Thumbnails/thumbnail.png \
extras_TPLPERSONAL_MIMETYPEFILES := $(foreach atexts,$(extras_TEMPLATES_PERSONAL),$(atexts)/mimetype)
ifneq ($(sort $(foreach file,$(extras_PERSONAL_XMLFILES),$(wordlist 1, 1, $(subst /, ,$(file))))),$(sort $(extras_TEMPLATES_PERSONAL)))
$(call gb_Output_error,defined template text do not match existing directories)
endif
$(call gb_CustomTarget_get_target,extras/source/templates/personal) : \
$(foreach atexts,$(extras_TEMPLATES_PERSONAL),$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)/$(atexts).ott)
$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)/%/mimetype : $(SRCDIR)/extras/source/templates/personal/%/mimetype
$(call gb_Output_announce,$*/mimetype,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)/%.jpg : $(SRCDIR)/extras/source/templates/personal/%.jpg
$(call gb_Output_announce,$*.jpg,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)/%.png : $(SRCDIR)/extras/source/templates/personal/%.png
$(call gb_Output_announce,$*.png,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)/%.rdf : $(SRCDIR)/extras/source/templates/personal/%.rdf
$(call gb_Output_announce,$*.rdf,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)/%.svg : $(SRCDIR)/extras/source/templates/personal/%.svg
$(call gb_Output_announce,$*.svg,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)/%.svm : $(SRCDIR)/extras/source/templates/personal/%.svm
$(call gb_Output_announce,$*.svm,$(true),CPY,1)
cp $< $@
$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)/%.xml : $(SRCDIR)/extras/source/templates/personal/%.xml \
| $(call gb_ExternalExecutable_get_dependencies,xsltproc)
$(call gb_Output_announce,$*.xml,$(true),XSL,1)
$(call gb_ExternalExecutable_get_command,xsltproc) --nonet -o $@ $(SRCDIR)/extras/util/compact.xsl $<
$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)/%.ott :
$(call gb_Output_announce,$*.ott,$(true),ZIP,2)
$(call gb_Helper_abbreviate_dirs,\
cd $(EXTRAS_PERSONAL_DIR) && \
zip -qrX --filesync --must-match $@ $(EXTRAS_PERSONAL_FILES) \
)
define extras_Tplpersonal_make_file_deps
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : $(SRCDIR)/$(1)/$(2) \
| $(dir $(call gb_CustomTarget_get_workdir,$(1))/$(2)).dir
endef
define extras_Tplpersonal_make_zip_deps
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
$(addprefix $(call gb_CustomTarget_get_workdir,$(1))/,$(filter $(3)/%,$(extras_TPLPERSONAL_MIMETYPEFILES) $(extras_PERSONAL_XMLFILES))) \
| $(dir $(call gb_CustomTarget_get_workdir,$(1))/$(2)).dir
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
EXTRAS_PERSONAL_FILES := $(foreach file,$(filter $(3)/%,$(extras_TPLPERSONAL_MIMETYPEFILES) $(extras_PERSONAL_XMLFILES)),$(subst $(3)/,,$(file)))
$(call gb_CustomTarget_get_workdir,$(1))/$(2) : \
EXTRAS_PERSONAL_DIR := $(call gb_CustomTarget_get_workdir,$(1))/$(3)
endef
$(eval $(foreach file,$(extras_TPLPERSONAL_MIMETYPEFILES) $(extras_PERSONAL_XMLFILES),\
$(call extras_Tplpersonal_make_zip_deps,extras/source/templates/personal,$(file)) \
))
$(eval $(foreach atexts,$(extras_TEMPLATES_PERSONAL),\
$(call extras_Tplpersonal_make_zip_deps,extras/source/templates/personal,$(atexts).ott,$(atexts)) \
))
# vim: set noet sw=4 ts=4:
......@@ -13,7 +13,11 @@ $(eval $(call gb_Module_add_targets,extras,\
CustomTarget_autocorr \
CustomTarget_autotextuser \
CustomTarget_glade \
CustomTarget_tplofficorr \
CustomTarget_tploffimisc \
CustomTarget_tplpersonal \
CustomTarget_tplpresnt \
CustomTarget_tpl_styles \
Package_autocorr \
Package_autotextuser \
Package_cfgsrvnolang \
......@@ -33,9 +37,9 @@ $(eval $(call gb_Module_add_targets,extras,\
Package_palettes \
Package_tplofficorr \
Package_tploffimisc \
Package_tplpersonal \
Package_tplpresnt \
Package_tpl_styles \
Package_tplpersonal \
Package_tplwizagenda \
Package_tplwizbitmap \
Package_tplwizdesktop \
......
......@@ -7,7 +7,7 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_Package_Package,extras_tpl_styles,$(SRCDIR)/extras/source/templates/styles))
$(eval $(call gb_Package_Package,extras_tpl_styles,$(call gb_CustomTarget_get_workdir,extras/source/templates/styles)))
$(eval $(call gb_Package_add_files,extras_tpl_styles,$(LIBO_SHARE_FOLDER)/template/common/styles,\
Default.ott \
......
......@@ -7,7 +7,7 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_Package_Package,extras_tplofficorr,$(SRCDIR)/extras/source/templates/officorr))
$(eval $(call gb_Package_Package,extras_tplofficorr,$(call gb_CustomTarget_get_workdir,extras/source/templates/officorr)))
$(eval $(call gb_Package_add_files,extras_tplofficorr,$(LIBO_SHARE_FOLDER)/template/common/officorr,\
Modern_business_letter_sans_serif.ott \
......
......@@ -7,7 +7,7 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_Package_Package,extras_tploffimisc,$(SRCDIR)/extras/source/templates/offimisc))
$(eval $(call gb_Package_Package,extras_tploffimisc,$(call gb_CustomTarget_get_workdir,extras/source/templates/offimisc)))
$(eval $(call gb_Package_add_files,extras_tploffimisc,$(LIBO_SHARE_FOLDER)/template/common/offimisc,\
Businesscard-with-logo.ott \
......
......@@ -7,7 +7,7 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_Package_Package,extras_tplpersonal,$(SRCDIR)/extras/source/templates/personal))
$(eval $(call gb_Package_Package,extras_tplpersonal,$(call gb_CustomTarget_get_workdir,extras/source/templates/personal)))
$(eval $(call gb_Package_add_files,extras_tplpersonal,$(LIBO_SHARE_FOLDER)/template/common/personal,\
CV.ott \
......
......@@ -36,3 +36,25 @@ How-to add a new Impress template
+ add files names contained in Foo.otp (except mimetype) in extras_PRESENTATIONS_XMLFILES
+ if Foo.otp contains files with other extension than .xml, .svm, .svg, .png and .jpg
+ add a CPY call at the end of file
How-to add a new Writer template
+ clean-up template file as much as possible, and choose a template category <Category>
+ unzip Foo.ott in extras/source/templates/<Category>/Foo (no space allowed in any file names)
+ add Foo.ott in Package_<tplCategory>.mk
+ in CustomTarget_<tplCategory>.mk:
+ add Foo / in extras_TEMPLATES_<CATEGORY>
+ add files names contained in Foo.otp (except mimetype) in extras_<CATEGORY>_XMLFILES
+ if Foo.ott contains files with other extension than .xml, rdf, .svm, .svg, .png and .jpg
+ add a CPY call at the end of file
How-to add a new template category
+ create a directory extras/source/templates/foo/
+ unzip your foo0.ott template files in extras/source/templates/foo/foo0
+ add Package_tplfoo and CustomTarget_tplfoo in Module_extras.mk
+ use other category Package_tplcategory.mk to create Package_tplfoo.mk
+ use other category CustomTarget_tplcategory.mk to create CustomTarget_tplfoo.mk
+ replace all category by foo and CATEGORY by FOO
+ add all files contained in foo0.ott (except mimetype) in extras_FOO_XMLFILES
+ if foo0.ott contains files with other extension than .xml, .rdf, .svm, .svg, .png and .jpg
+ add a CPY call at the end of the file
+ optionaly, replace extension ott (4 places)
<?xml version="1.0" encoding="UTF-8"?>
<manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0" manifest:version="1.2">
<manifest:file-entry manifest:full-path="/" manifest:version="1.2" manifest:media-type="application/vnd.oasis.opendocument.text-template"/>
<manifest:file-entry manifest:full-path="Thumbnails/thumbnail.png" manifest:media-type="image/png"/>
<manifest:file-entry manifest:full-path="content.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="meta.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="manifest.rdf" manifest:media-type="application/rdf+xml"/>
<manifest:file-entry manifest:full-path="styles.xml" manifest:media-type="text/xml"/>
</manifest:manifest>
<?xml version="1.0" encoding="utf-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="styles.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#StylesFile"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="styles.xml"/>
</rdf:Description>
<rdf:Description rdf:about="content.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#ContentFile"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="content.xml"/>
</rdf:Description>
<rdf:Description rdf:about="">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#Document"/>
</rdf:Description>
</rdf:RDF>
<?xml version="1.0" encoding="UTF-8"?>
<office:document-meta xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:grddl="http://www.w3.org/2003/g/data-view#" office:version="1.2">
<office:meta>
<meta:creation-date>2017-08-04T08:52:31.981207423</meta:creation-date>
<meta:editing-duration>PT39S</meta:editing-duration>
<meta:editing-cycles>2</meta:editing-cycles>
<meta:generator>LibreOffice/5.3.4.2$Linux_X86_64 LibreOffice_project/30$Build-2</meta:generator>
<dc:description>Modern business letter with sans-serif font </dc:description>
<dc:title>Modern business letter sans-serif</dc:title>
<meta:initial-creator>Eric Lavarde</meta:initial-creator>
<dc:date>2017-08-04T08:53:09.944969205</dc:date>
<dc:creator>Eric Lavarde</dc:creator>
<meta:document-statistic meta:table-count="0" meta:image-count="0" meta:object-count="0" meta:page-count="1" meta:paragraph-count="10" meta:word-count="149" meta:character-count="997" meta:non-whitespace-character-count="847"/>
</office:meta>
</office:document-meta>
application/vnd.oasis.opendocument.text-template
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0" manifest:version="1.2">
<manifest:file-entry manifest:full-path="/" manifest:version="1.2" manifest:media-type="application/vnd.oasis.opendocument.text-template"/>
<manifest:file-entry manifest:full-path="Thumbnails/thumbnail.png" manifest:media-type="image/png"/>
<manifest:file-entry manifest:full-path="styles.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="content.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="meta.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="manifest.rdf" manifest:media-type="application/rdf+xml"/>
</manifest:manifest>
<?xml version="1.0" encoding="utf-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="styles.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#StylesFile"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="styles.xml"/>
</rdf:Description>
<rdf:Description rdf:about="content.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#ContentFile"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="content.xml"/>
</rdf:Description>
<rdf:Description rdf:about="">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#Document"/>
</rdf:Description>
</rdf:RDF>
<?xml version="1.0" encoding="UTF-8"?>
<office:document-meta xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:grddl="http://www.w3.org/2003/g/data-view#" office:version="1.2">
<office:meta>
<meta:creation-date>2014-12-28T11:41:10.830000000</meta:creation-date>
<meta:editing-duration>PT17M45S</meta:editing-duration>
<meta:editing-cycles>2</meta:editing-cycles>
<meta:generator>LibreOffice/4.3.5.2$Windows_x86 LibreOffice_project/3a87456aaa6a95c63eea1c1b3201acedf0751bd5</meta:generator>
<dc:description>Modern business letter with serif font</dc:description>
<dc:title>Modern business letter serif</dc:title>
<dc:date>2014-12-28T11:58:55.267000000</dc:date>
<meta:document-statistic meta:table-count="0" meta:image-count="0" meta:object-count="0" meta:page-count="1" meta:paragraph-count="10" meta:word-count="151" meta:character-count="1009" meta:non-whitespace-character-count="860"/>
</office:meta>
</office:document-meta>
application/vnd.oasis.opendocument.text-template
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0" manifest:version="1.2">
<manifest:file-entry manifest:full-path="/" manifest:version="1.2" manifest:media-type="application/vnd.oasis.opendocument.text-template"/>
<manifest:file-entry manifest:full-path="Thumbnails/thumbnail.png" manifest:media-type="image/png"/>
<manifest:file-entry manifest:full-path="content.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="settings.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="meta.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="Pictures/10000201000001F4000000A0108F3F06.png" manifest:media-type="image/png"/>
<manifest:file-entry manifest:full-path="styles.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="manifest.rdf" manifest:media-type="application/rdf+xml"/>
</manifest:manifest>
This source diff could not be displayed because it is too large. You can view the blob instead.
<?xml version="1.0" encoding="utf-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="styles.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#StylesFile"/>
</rdf:Description>
<rdf:Description rdf:about="">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#Document"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="content.xml"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="styles.xml"/>
</rdf:Description>
<rdf:Description rdf:about="content.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#ContentFile"/>
</rdf:Description>
</rdf:RDF>
<?xml version="1.0" encoding="UTF-8"?>
<office:document-meta xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:grddl="http://www.w3.org/2003/g/data-view#" office:version="1.2">
<office:meta>
<meta:generator>LibreOffice/4.3.5.2$Linux_X86_64 LibreOffice_project/430m0$Build-2</meta:generator>
<meta:creation-date>2014-12-30T23:56:58.865996821</meta:creation-date>
<meta:editing-cycles>1</meta:editing-cycles>
<meta:editing-duration>P0D</meta:editing-duration>
<dc:title>Businesscard with logo</dc:title>
<meta:document-statistic meta:table-count="10" meta:image-count="10" meta:object-count="0" meta:page-count="1" meta:paragraph-count="105" meta:word-count="110" meta:character-count="680" meta:non-whitespace-character-count="650"/>
</office:meta>
</office:document-meta>
application/vnd.oasis.opendocument.text-template
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0" manifest:version="1.2">
<manifest:file-entry manifest:full-path="/" manifest:version="1.2" manifest:media-type="application/vnd.oasis.opendocument.text-template"/>
<manifest:file-entry manifest:full-path="Thumbnails/thumbnail.png" manifest:media-type="image/png"/>
<manifest:file-entry manifest:full-path="styles.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="content.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="meta.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="manifest.rdf" manifest:media-type="application/rdf+xml"/>
</manifest:manifest>
This diff is collapsed.
<?xml version="1.0" encoding="utf-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="styles.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#StylesFile"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="styles.xml"/>
</rdf:Description>
<rdf:Description rdf:about="content.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#ContentFile"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="content.xml"/>
</rdf:Description>
<rdf:Description rdf:about="">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#Document"/>
</rdf:Description>
</rdf:RDF>
<?xml version="1.0" encoding="UTF-8"?>
<office:document-meta xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:grddl="http://www.w3.org/2003/g/data-view#" office:version="1.2">
<office:meta>
<meta:generator>LibreOffice/4.3.4.1$Windows_x86 LibreOffice_project/bc356b2f991740509f321d70e4512a6a54c5f243</meta:generator>
<meta:creation-date>2014-12-22T14:19:34.120000000</meta:creation-date>
<meta:editing-cycles>2</meta:editing-cycles>
<meta:editing-duration>PT2M</meta:editing-duration>
<meta:initial-creator>Alexander Wilms</meta:initial-creator>
<dc:date>2014-12-22T14:21:26.257000000</dc:date>
<dc:creator>Alexander Wilms</dc:creator>
<dc:title>CV</dc:title>
<meta:document-statistic meta:table-count="1" meta:image-count="0" meta:object-count="0" meta:page-count="1" meta:paragraph-count="40" meta:word-count="125" meta:character-count="767" meta:non-whitespace-character-count="678"/>
<meta:user-defined meta:name="Info 1"/>
<meta:user-defined meta:name="Info 2"/>
<meta:user-defined meta:name="Info 3"/>
<meta:user-defined meta:name="Info 4"/>
</office:meta>
</office:document-meta>
application/vnd.oasis.opendocument.text-template
\ No newline at end of file
This diff is collapsed.
<?xml version="1.0" encoding="UTF-8"?>
<manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0" manifest:version="1.2">
<manifest:file-entry manifest:full-path="/" manifest:version="1.2" manifest:media-type="application/vnd.oasis.opendocument.text-template"/>
<manifest:file-entry manifest:full-path="Thumbnails/thumbnail.png" manifest:media-type="image/png"/>
<manifest:file-entry manifest:full-path="content.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="meta.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="styles.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="manifest.rdf" manifest:media-type="application/rdf+xml"/>
</manifest:manifest>
<?xml version="1.0" encoding="utf-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="styles.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#StylesFile"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="styles.xml"/>
</rdf:Description>
<rdf:Description rdf:about="content.xml">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#ContentFile"/>
</rdf:Description>
<rdf:Description rdf:about="">
<ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="content.xml"/>
</rdf:Description>
<rdf:Description rdf:about="">
<rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#Document"/>
</rdf:Description>
</rdf:RDF>
<?xml version="1.0" encoding="UTF-8"?>
<office:document-meta xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:grddl="http://www.w3.org/2003/g/data-view#" office:version="1.2">
<office:meta>
<meta:creation-date>2015-01-01T00:31:10.577014951</meta:creation-date>
<meta:editing-duration>PT18S</meta:editing-duration>
<meta:editing-cycles>2</meta:editing-cycles>
<meta:generator>LibreOffice/4.3.3.2$Linux_X86_64 LibreOffice_project/430m0$Build-2</meta:generator>
<dc:title>Resume</dc:title>
<dc:date>2015-01-01T00:36:20.456620209</dc:date>
<meta:document-statistic meta:table-count="0" meta:image-count="0" meta:object-count="0" meta:page-count="1" meta:paragraph-count="25" meta:word-count="76" meta:character-count="388" meta:non-whitespace-character-count="331"/>
</office:meta>
</office:document-meta>
application/vnd.oasis.opendocument.text-template
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0" manifest:version="1.2">
<manifest:file-entry manifest:full-path="/" manifest:version="1.2" manifest:media-type="application/vnd.oasis.opendocument.text-template"/>
<manifest:file-entry manifest:full-path="Thumbnails/thumbnail.png" manifest:media-type="image/png"/>
<manifest:file-entry manifest:full-path="styles.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="meta.xml" manifest:media-type="text/xml"/>
</manifest:manifest>
<?xml version="1.0" encoding="UTF-8"?>
<office:document-meta xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:grddl="http://www.w3.org/2003/g/data-view#" office:version="1.2">
<office:meta>
<meta:creation-date>2015-04-17T18:49:20.216881797</meta:creation-date>
<dc:date>2015-04-17T18:51:02.799210624</dc:date>
<dc:title>Default</dc:title>
<meta:editing-cycles>1</meta:editing-cycles>
</office:meta>
</office:document-meta>
application/vnd.oasis.opendocument.text-template
\ No newline at end of file
This diff is collapsed.
<?xml version="1.0" encoding="UTF-8"?>
<manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0" manifest:version="1.2">
<manifest:file-entry manifest:full-path="/" manifest:version="1.2" manifest:media-type="application/vnd.oasis.opendocument.text-template"/>
<manifest:file-entry manifest:full-path="Thumbnails/thumbnail.png" manifest:media-type="image/png"/>
<manifest:file-entry manifest:full-path="meta.xml" manifest:media-type="text/xml"/>
<manifest:file-entry manifest:full-path="styles.xml" manifest:media-type="text/xml"/>
</manifest:manifest>
<?xml version="1.0" encoding="UTF-8"?>
<office:document-meta xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:grddl="http://www.w3.org/2003/g/data-view#" office:version="1.2">
<office:meta>
<meta:creation-date>2015-04-17T19:07:06.576326607</meta:creation-date>
<dc:date>2015-04-17T19:11:21.808309920</dc:date>
<dc:title>Modern</dc:title>
</office:meta>
</office:document-meta>
application/vnd.oasis.opendocument.text-template
\ No newline at end of file
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment