From f89860807baaa901629ce2a814b7a6c994318fe5 Mon Sep 17 00:00:00 2001 From: Rafael Lima Date: Sat, 13 Feb 2021 16:43:01 +0100 Subject: Resolves tdf#140221 auto-adjust Formula Editor width Currently the formula editor uses a fixed width that corresponds to about half the size of the display. This patch makes the formula editor auto adjust. Change-Id: I0cd6a6385b698fced96132a636df2d24c6c62cf1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110862 Tested-by: Jenkins Reviewed-by: Adolfo Jayme Barrientos --- starmath/source/edit.cxx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/starmath/source/edit.cxx b/starmath/source/edit.cxx index a425e20f4b0e..64d1fc34757e 100644 --- a/starmath/source/edit.cxx +++ b/starmath/source/edit.cxx @@ -294,6 +294,10 @@ void SmEditWindow::Resize() if (pEditView) { + // Resizes the edit engine to adjust to the size of the output area + const Size aSize( pEditView->GetOutputArea().GetSize() ); + pEditView->GetEditEngine()->SetPaperSize(aSize); + pEditView->SetOutputArea(AdjustScrollBars()); pEditView->ShowCursor(); -- cgit