Files
odfstudio/sc/UITest_sc_styleui.mk
T
Paolo Benvenuto 42cdc47554 tdf#92144 Enable relative font sizes in Calc cell styles
Writer paragraph styles already support percentage-based (80%, 115%)
and point-relative (+2pt, -4pt) font sizes for child styles inheriting
from a parent. Calc cell styles lacked this despite using the same
underlying SvxCharNamePage and FontSizeBox widgets.

The root cause was that Calc's ScStyleDlg::PageCreated() did not pass
the SVX_RELATIVE_MODE flag when creating the font tab page, so
FontSizeBox::EnableRelativeMode() and EnablePtRelativeMode() were
never called.

The fix adds a single SfxUInt32Item(SID_FLAG_TYPE, SVX_RELATIVE_MODE)
to the item set passed to the font page, matching what Writer's
SwTemplateDlgController already does.

No changes are needed in the core: SvxFontHeightItem::SetHeight()
already pre-calculates absolute values from relative ones, and
ScPatternAttr works correctly with these pre-calculated values.

Fix found with the help of Claude Sonnet 4.6 extended.

Change-Id: I3d759c028564a4722f96b325499ea0bfe8e4ba07
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/200885
Tested-by: Jakub Trzebiatowski <ubap.dev@gmail.com>
Tested-by: Jenkins
Reviewed-by: Jakub Trzebiatowski <ubap.dev@gmail.com>
2026-04-23 18:12:35 +02:00

20 lines
642 B
Makefile

# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t; fill-column: 100 -*-
#
# 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_UITest_UITest,sc_styleui))
$(eval $(call gb_UITest_add_modules,sc_styleui,$(SRCDIR)/sc/qa/uitest,\
styleui/ \
))
$(eval $(call gb_UITest_set_defs,sc_styleui, \
TDOC="$(SRCDIR)/sc/qa/uitest/data" \
))
$(eval $(call gb_UITest_avoid_oneprocess,sc_styleui))
# vim: set noet sw=4 ts=4: