From 4d2e74a353338f55452aee22104ee62d09a5aeb3 Mon Sep 17 00:00:00 2001 From: wp_xyz Date: Wed, 1 Jun 2022 00:30:14 +0200 Subject: [PATCH] Turbopower_ipro: Fix alignment of text in table cells, issue #39767. --- components/turbopower_ipro/iphtmlblocklayout.pas | 2 +- components/turbopower_ipro/test_cases/test-results.txt | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/components/turbopower_ipro/iphtmlblocklayout.pas b/components/turbopower_ipro/iphtmlblocklayout.pas index 1234579245..3924d39a14 100644 --- a/components/turbopower_ipro/iphtmlblocklayout.pas +++ b/components/turbopower_ipro/iphtmlblocklayout.pas @@ -536,7 +536,7 @@ begin lAlign := FAl; node := aCurElem.Owner.ParentNode; while Assigned(node) do begin - if (node is TIpHtmlNodeCore) then + if (node is TIpHtmlNodeP) or (node is TIpHtmlNodeDIV) or (node is TIpHtmlNodeTableHeaderOrCell) then lAlign := TIpHtmlNodeCore(node).Align else break; diff --git a/components/turbopower_ipro/test_cases/test-results.txt b/components/turbopower_ipro/test_cases/test-results.txt index e4e05a8977..06372562bc 100644 --- a/components/turbopower_ipro/test_cases/test-results.txt +++ b/components/turbopower_ipro/test_cases/test-results.txt @@ -4,7 +4,7 @@ c745e8b8e7bf5afeb32f6e40066b8f20|1 1a73bf758f9ffb962746faaf13b8f166|1 faf187bf6662c4dc9010c89e52fd9c05|1 b04ecc7eb166dd8432afebddaaa6ca7c|1 -faffbd13f323d19002d5319afddecf30|0 +faffbd13f323d19002d5319afddecf30|1 c34635385386c1ff8e77236b31e4c684|1 ab7d8098373c01ae729e8a9e3e0ed3a0|1 76f9fb06074c7bc161b07fea5a278a16|1 @@ -14,6 +14,8 @@ f410a0a721b9a5d3e43e4134d05d55e1|0 3893ea2a37335b97594c2e034727ef6e|1 db425850a781ed8fc7fa450adf36367f|1 d5068632b7f322c1076e0e78442ae6a3|1 +3f26df1d86af1027854ce26d46ce2c2e|1 +11f3124a2c6346c91fd6f5ec369bfff4|1 c9798563026960f2332ed2fe9bc74b61|1 0f50b75c007ba031862243f4cb9cd99b|1 eadb0b01c9e5cb899dd67a83e9edfe1f|0