Exporting a document to PDF/UA-2 produced a file that fails ISO 14289-2 clause 8.8, once per outline item and internal link. veraPDF reports Destination in Outline item, OpenAction or Link annotation is not a structure destination The destination named the page and an area on it, and that is all: what was linked to could only be worked out by looking at what the layout had put at that position. A destination for a link or an outline item is now written as a GoTo action carrying a structure destination beside the page one (ISO 32000-2 12.3.2.3): /A<</Type/Action/S/GoTo/D[<page> 0 R/XYZ ...]/SD[<elem> 0 R/XYZ ...]>> sw creates a destination before its target is tagged, so the node is remembered while the cursor is on it, and matched against the tags in the pass that already runs after the last page. Creating one and remembering its node is a single call now, which every destination a link or an outline item points at goes through: bibliography entries and links in the text of a shape are named as well. The cursor is not always on the target: a jump that selects a frame or a drawing object, and one that finds nothing, move it nowhere, and where it was left standing on the link, that link's own element must not become the target. The pass over a shape's links can instead start with the cursor on the target already, where a jump that did reach it shows no move either, so there the mark names its own node. Those keep writing /Dest, as do a target that was never tagged and one whose element was never emitted. The element carries its role and its content, not a name of its own: a heading becomes /S/H1 with no /Alt or /T. veraPDF does not check what a structure destination points at, so the test does. Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com> Change-Id: Ic76d80d46f130d549ebaacf175393a3d6ec77998 Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/12300 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins CPCI <releng@collaboraoffice.com> (cherry picked from commit a6502c6e96d13425bcb4a3bf5731a998982d5957) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211150 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
90 lines
2.2 KiB
Makefile
90 lines
2.2 KiB
Makefile
# -*- 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_CppunitTest_CppunitTest,sw_core_text))
|
|
|
|
$(eval $(call gb_CppunitTest_use_common_precompiled_header,sw_core_text))
|
|
|
|
$(eval $(call gb_CppunitTest_add_exception_objects,sw_core_text, \
|
|
sw/qa/core/text/EnhancedPDFExportHelper \
|
|
sw/qa/core/text/frmform \
|
|
sw/qa/core/text/itratr \
|
|
sw/qa/core/text/itrpaint \
|
|
sw/qa/core/text/itrform2 \
|
|
sw/qa/core/text/porfld \
|
|
sw/qa/core/text/porlay \
|
|
sw/qa/core/text/porrst \
|
|
sw/qa/core/text/text \
|
|
sw/qa/core/text/txtfly \
|
|
sw/qa/core/text/widorp \
|
|
))
|
|
|
|
$(eval $(call gb_CppunitTest_use_libraries,sw_core_text, \
|
|
comphelper \
|
|
cppu \
|
|
cppuhelper \
|
|
editeng \
|
|
sal \
|
|
sfx \
|
|
subsequenttest \
|
|
svl \
|
|
svt \
|
|
sw \
|
|
swqahelper \
|
|
test \
|
|
tl \
|
|
unotest \
|
|
utl \
|
|
vcl \
|
|
$(if $(filter -fsanitize=vptr,$(gb_CXX)),svxcore) \
|
|
))
|
|
|
|
$(eval $(call gb_CppunitTest_use_externals,sw_core_text,\
|
|
boost_headers \
|
|
libxml2 \
|
|
))
|
|
|
|
$(eval $(call gb_CppunitTest_set_include,sw_core_text,\
|
|
-I$(SRCDIR)/sw/inc \
|
|
-I$(SRCDIR)/sw/source/core/inc \
|
|
-I$(SRCDIR)/sw/source/core/text \
|
|
-I$(SRCDIR)/sw/source/uibase/inc \
|
|
-I$(SRCDIR)/sw/qa/inc \
|
|
$$(INCLUDE) \
|
|
))
|
|
|
|
$(eval $(call gb_CppunitTest_use_api,sw_core_text,\
|
|
udkapi \
|
|
offapi \
|
|
oovbaapi \
|
|
))
|
|
|
|
$(eval $(call gb_CppunitTest_use_ure,sw_core_text))
|
|
$(eval $(call gb_CppunitTest_use_vcl,sw_core_text))
|
|
|
|
$(eval $(call gb_CppunitTest_use_rdb,sw_core_text,services))
|
|
|
|
$(eval $(call gb_CppunitTest_use_custom_headers,sw_core_text,\
|
|
officecfg/registry \
|
|
))
|
|
|
|
$(eval $(call gb_CppunitTest_use_configuration,sw_core_text))
|
|
|
|
$(eval $(call gb_CppunitTest_use_uiconfigs,sw_core_text, \
|
|
modules/swriter \
|
|
sfx \
|
|
svt \
|
|
))
|
|
|
|
$(eval $(call gb_CppunitTest_use_more_fonts,sw_core_text))
|
|
|
|
# vim: set noet sw=4 ts=4:
|