In a text document insert a table; select several cells in it; run the following BASIC code: > Sub ColorizeTable1 > ThisComponent.getCurrentSelection().BackColor = &H00FF0000 > End Sub Expected result is the cells having red background. Actual result is cells' paragraphs get red background, which makes cells have white spacing. Compare to > Sub ColorizeTable2 > ThisComponent.getTextTables().getByIndex(0).getCellRangeByName("A1:A1").BackColor = &H00FF0000 > End Sub which correctly does the job. Both SwXTextTableCursor::setPropertyValue and SwXCellRange::setPropertyValue do the same thing: they check for FN_UNO_TABLE_CELL_BACKGROUND to apply the value to the cells [1]. For SwXCellRange, property name "BackColor" correctly maps to that value. But in case of SwXTextTableCursor, neither "BackColor", nor any other name maps to FN_UNO_TABLE_CELL_BACKGROUND, making it impossible to apply cell color using text table cursor. The same for getPropertyValue. Tested in Version: 6.4.0.1 (x64) Build ID: 1b6477b31f0334bd8620a96f0aeeb449b587be9f CPU threads: 12; OS: Windows 10.0 Build 18363; UI render: default; VCL: win; Locale: ru-RU (ru_RU); UI-Language: en-US Calc: threaded and in OpenOffice.org 2.2.0 but not in OpenOffice.org 1.0.3 Regression after https://git.libreoffice.org/core/+/eba784710e92597282a2284b56dce3a45ac38776 [1] https://opengrok.libreoffice.org/xref/core/sw/source/core/unocore/unotbl.cxx?r=24314773
https://gerrit.libreoffice.org/c/core/+/86315
Mike Kaganski committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/ecb5130e16898c0d2485e99564c57882b5ef25b0 tdf#129841: fix GetTextTableCursorPropertyMap cell background values It will be available in 6.5.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Mike Kaganski committed a patch related to this issue. It has been pushed to "libreoffice-6-4": https://git.libreoffice.org/core/commit/fd3be6be5c9dc9a96834261c280fc291ed089835 tdf#129841: fix GetTextTableCursorPropertyMap cell background values It will be available in 6.4.0.2. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.