summaryrefslogtreecommitdiff
path: root/sw
AgeCommit message (Collapse)Author
2022-05-31sw content controls, date: add insert UIMiklos Vajna
- handle the date case in SwWrtShell::InsertContentControl() - expose this as a new .uno:InsertDateContentControl command - add the new uno command to the default & MS-compatible menus - hide the old .uno:DatePickerFormField from the menus that has the problems described in the sw::mark::DateFieldmark documentation. Change-Id: If3c1050d6a8302be0da4a11067a67805396dec48 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135153 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-31date picker should rather show the current date instead of February 14, 2019Andras Timar
Change-Id: Ie449873aad40b6f02198a8a44a7eae1aaba1cfae Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135148 Tested-by: Jenkins Reviewed-by: Andras Timar <andras.timar@collabora.com>
2022-05-30Use more appropriate index variable typeStephan Bergmann
Change-Id: Ieb3ed7931361e38ce62cd4dfa98b9712e4181d03 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135145 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2022-05-30tdf#145178: sw: Add UItestXisco Fauli
Change-Id: I5dbc302216b0d8b94ad29a336495856ce8cfc4b9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135139 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-05-30-Werror=maybe-uninitializedStephan Bergmann
> sw/source/core/text/guess.cxx: In member function ‘bool SwTextGuess::Guess(const SwTextPortion&, SwTextFormatInfo&, sal_uInt16)’: > sw/source/core/text/guess.cxx:220:37: error: ‘bHyphenationNoLastWord’ may be used uninitialized [-Werror=maybe-uninitialized] > 220 | if ( bHyphenationNoLastWord && sal_Int32(m_nCutPos) > nLastWord ) > | ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > sw/source/core/text/guess.cxx:201:14: note: ‘bHyphenationNoLastWord’ was declared here > 201 | bool bHyphenationNoLastWord; > | ^~~~~~~~~~~~~~~~~~~~~~ since 8c018910ae4d8701b1ce2a95727b9baed4016da3 "tdf#149248 sw offapi xmloff: add option to not hyphenate last word" Change-Id: Id3be25bf9f5d6769555bfe461a0f4e1e27e0e39e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135137 Reviewed-by: László Németh <nemeth@numbertext.org> Tested-by: Jenkins
2022-05-30tdf#147708 create floating menubutton on demandCaolán McNamara
and destroy when it is fully faded out. Otherwise windows runs out of gdi handles with document with large number of page breaks todo: rename some things in a follow up commit after this more easily backportable commit is merged Change-Id: Ibbe3cd00d1027ac34915c4bff73e3a330e300f38 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135027 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-05-30use more SfxWhichIter::GetItemStateNoel Grandin
Change-Id: Iae284fcad199684920aef0bd91ff39c407b48e0a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135125 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-30these can be stack allocatedNoel Grandin
Change-Id: I7be63816fcdc3572d751fdd9ceab5931d0559ffc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135124 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-30tdf#146272 sw: fix fly in fly hid by incomplete z-orderingAttila Bakos (NISZ)
Fixing z-order was incomplete for textboxes (shape + frame pair), because only the frame moved to back, but not the shape, covering the textbox. Regression from commit 504d78acb866495fd954fcd6db22ea68f174a5ab "tdf#143574 sw: textboxes in group shapes - part 1". See also commit 0e6d963fbca16f98a3dbb6ef2fee3736a89d055b "tdf#138141 sw: fix textbox z-order". Change-Id: I03e3b55302c984e5968e579e77ccd5ed0a336dd9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134942 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2022-05-30tdf#149200: docx export: transparent color fixVasily Melenchuk
If there is no color value we should not also try to write transparency information: otherwise w:srgbClr will have no parameter value and MS Word won't open such documents. Change-Id: Id67f174c5ae9aadf90ae54c126aef9a43ff3ba17 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134945 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
2022-05-30sw: prefix members of CompareDrawObjs, SwBasicEscherEx, ...Miklos Vajna
... WW8AttributeOutput and wwSection See tdf#94879 for motivation. Change-Id: Iefc7aaf4caaaca5382ac0b28ea8e3ebe63250020 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135108 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-30sw content controls, date: add DOCX importMiklos Vajna
- map <w:date> <w:dateFormat w:val="..."/> <w:lid w:val="..."/> </w:date> to the Date, DateFormat and DateLanguage UNO properties of content controls instead of fieldmarks, which model content controls poorly - fix CppunitTest_sw_ooxmlexport8's testN820509: date SDT is now a content control - add current date DOCX import - fix CppunitTest_sw_ooxmlexport13's testDateControl: date SDT is now a content control - fix CppunitTest_sw_ooxmlexport13's testInvalidDateFormField: date SDT is now a content control - fix CppunitTest_sw_ooxmlexport5's testfdo83048: minimal support for nested SDTs in DomainMapper::lcl_attribute() - fix CppunitTest_sw_ooxmlfieldexport's testDateFieldAtEndOfParagraph: date SDT is now a content control - fix CppunitTest_sw_ooxmlfieldexport's testDateFieldInShape: date SDT is now a content control - fix CppunitTest_sw_ooxmlfieldexport's testSdtDateDuplicate: date SDT is now a content control - fix CppunitTest_sw_ooxmlfieldexport's testSdtDatePicker: - retain placeholder - retain data binding - retain color - fix CppunitTest_sw_ooxmlimport2's testTdf121203: date SDT is now a content control - fix CppunitTest_sw_globalfilter's testDateFormFieldCharacterFormatting: date SDT is now a content control - fix CppunitTest_sw_globalfilter's testDateFormField: date SDT is now a content control Change-Id: I5a4c34217d23ed6fa0916e4dd6290351456b7232 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135109 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-29cid#1504583 Unchecked return valueCaolán McNamara
Change-Id: I172057b76ff4e6e1cf3d5e67a99360ecfc0a3fc3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135081 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-05-28add ClearItem to the SfxItemSet iteratorsNoel Grandin
to speed up operations when iterating over SfxItemSets Change-Id: Ie40327ffaf7faa801ccc12d2b05c546a7fe49802 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135079 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-28add GetItemState to SfxItemIter, the same way I did to SfxWhichIterNoel Grandin
to speed up GetItemState while iterating Change-Id: Ibe092e7581a5be0160eed52472122afe7e0ef377 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135076 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-28use the new SfxWhichIter::GetItemState featureNoel Grandin
to speed up other places that are iterating over SfxItemSets Change-Id: I646bae12420d15e67effdd279e071cdf8a8afffd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135075 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-27tdf#145875 don't open Insert section dialog when pasting imageSzymon Kłos
This happens when we "copy image" in Firefox of the resource which cannot be accessed without logging in on some website. In that case we used HTML format and that resulted in pasting login webpage as a section. This patch detects simple HTML containing only an image while it also contains BITMAP format in the clipboard which we can use directly. That way we paste image data from the clipboard. Change-Id: Ia2ee7e246f8c71e1d0958c6c955ec056a0a96f8c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135011 Tested-by: Jenkins Reviewed-by: Andras Timar <andras.timar@collabora.com>
2022-05-27sw content controls, date: preserve more propertiesMiklos Vajna
While working on the DOCX import for dates, it turns out there is a need to store more properties for DOCX export purposes. Given that these are potentially useful for full support, add dedicated UNO API and DOCX export for these (i.e. not just grab-bag), but omit UI or ODT filter for now. This includes: - <w:docPart w:val="..."> - <w:dataBinding w:prefixMappings="..." w:xpath="..." w:storeItemID="..."> - <w15:color w:val="..."> And tests for all these. Change-Id: I18ddec50d40c1c4abd87f7ea947a24dd8a92a755 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135039 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-27sw content controls, date: add current date handlingMiklos Vajna
While working on the DOCX import for dates, it turns out there is a need to store the selected date in machine-readable format as well. This is useful, because once the timestamp is formatted, the user is allowed to hand-edit the result, so otherwise the selected date would be lost. This commit adds: - doc model & UNO API - click handler (store the selected date, default to the current date in the date picker if possible) - ODT filter - DOCX export And tests for all these. Change-Id: I00f4e87ebfe0e8a19486367c32d472ccd2ff16a8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135035 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-27tdf#149268: sw: Add UItestXisco Fauli
Change-Id: I5a7af83d1d97e009c9bd313b936c6b6d4ee48116 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135016 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-05-27sw: language fallback in MSWordExportBase::GetNumberFormat()Michael Stahl
There is this number format: <number:date-style style:name="N36" number:automatic-order="true"> <number:day number:style="long"/> <number:text>.</number:text> <number:month number:style="long"/> <number:text>.</number:text> <number:year number:style="long"/> </number:date-style> in a paragraph which has fo:language="zxx", so the field has LANGUAGE_NONE. MSWordExportBase::GetNumberFormat() exports as: DATE \@"dd/MM/yyyy" But should be: DATE \@"dd.MM.yyyy" Follow Eike's suggestion to use the number format's language in case the field doesn't have one. Change-Id: I596bea5daa75c717931b3c5d5506103b87b8ee08 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134638 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2022-05-27tdf#148365 sw: fix freezing with FrameIsAutomaticHeightAttila Bakos (NISZ)
Lock layout update temporarily during setting horizontal and after that, vertical orientations of textboxes with FrameIsAutomaticHeight to avoid freezing SwObjectFormatter, and depending on the platform, freezing Writer completely. Regression from commit 3b0a0e70cb67fc2e1f9999d2e8cbb9cfcd8c670e "Related tdf#66039 DOCX import: fix Z-order of group shapes". Change-Id: Ib106182b9f0d3d74ebdc3e746345380c8b685fdf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134480 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2022-05-27tdf#149268 avoid null pointer dereferenceJim Raykowski
Change-Id: Iff3aece9eaed40c31764616504f1a4229db57e01 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134978 Tested-by: Jenkins Tested-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2022-05-27sw content controls, date: add DOCX exportMiklos Vajna
Map the Date, DateFormat and DateLanguage UNO properties to: <w:date> <w:dateFormat w:val="..."/> <w:lid w:val="..."/> </w:date> Change-Id: I4695ac30be26968b2c2ea14b044c1e2a10638ea8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135033 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-27CppunitTest_sw_layoutwriter: use more SwParaPortion::dumpAsXml()Miklos Vajna
See commit feeed3e762cf077fbd9cf48f82e949365108ccc1 (CppunitTest_sw_layoutwriter: avoid some a11y-based layout testing, 2022-04-07) for motivation. Change-Id: Icbf2c3b4c1dfcdf551ea8c1f1f9520449b55289a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135029 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-05-26tdf#146955 DOCX import: fix SAX exception with footnotesLászló Németh
(Likely broken) DOCX documents exported by Writer raised a SAX exception, when PopFootOrEndnote() tried to access to a not-existent footnote, because PushFootOrEndnote() failed to create that. Note: the original ODT contains hundreds of frames, and these and the text content of the document have been put into the TOC section during Writer's DOCX export, resulting a broken document. Regression from commit 9b39ce0e66acfe812e1d50e530dc2ccdef3e1357 "tdf#76260 DOCX import: fix slow footnote import". Change-Id: I9e32feb0cae778a87f034a8b5c41989fec90899d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134934 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org>
2022-05-26tdf#149324 sw offapi xmloff: add option to not hyphenate short wordsLászló Németh
Add paragraph property to disable automatic hyphenation of short words based on a minimum character count. Note: there is a (broken) global option for Minimum Word Length at hyphenation, see "Minimal number of characters for hyphenation" in Tools->Options->Language Settings->Writing Aids), but for better/comfortable paragraph-level adjustment of typesetting, add a paragraph property for it. The same option is available e.g. in Adobe InDesign and in CSS Text Module Level 4 (hyphenate-limit-chars). * Add checkbox to Text Flow in paragraph dialog * Store property in paragraph model (com::sun::star::style::ParagraphProperties::ParaHyphenationMinWordLength) * Add ODF import/export * Add ODF unit test * Add layout test Follow-up to commit 8c018910ae4d8701b1ce2a95727b9baed4016da3 "tdf#149248 sw offapi xmloff: add option to not hyphenate last word". Change-Id: I68715f47d17b5c022430bd0e74c88a97bc7f81f9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135028 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org>
2022-05-26Fix typoAndrea Gelmini
Change-Id: Id418d65ce165d93e84463ae321ca2db869e857cc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134670 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-05-26Fix typosAndrea Gelmini
Change-Id: I12273f1193a4089743b8e5a9716432e065930cc5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134990 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-05-26sw content controls, picture: add LOK API testcaseMiklos Vajna
Fails with commit 9a76be53dfb801b754bf55f9d4b8c5f82991a62f (sw content controls, picture: add LOK API, 2022-05-23) reverted. Change-Id: I6164e597099632a2212afee86ac9a4c7555e5c61 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135022 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-26tdf#149248 sw offapi xmloff: add option to not hyphenate last wordLászló Németh
Add option to disable automatic hyphenation of the last word of paragraphs for better typography. Note: the same option used e.g. in Adobe InDesign, and a similar one in CSS Text Module Level 4 (hyphenate-limit-last). * Add checkbox to Text Flow in paragraph dialog * Store property in paragraph model (com::sun::star::style::ParagraphProperties::ParaHyphenationNoLastWord) * Add ODF import/export * Add ODF unit test * Add layout test Follow-up to commit 72bd0df107ee47c4d54fa88b4960d32ea03e9f69 "tdf#121658 Add option to not hyphenate words in CAPS". Change-Id: Ida29c65b5a7cbfd7c399c342781531a6fb86f639 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134985 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org>
2022-05-26avoid some allocation in SwDoc::ResetAttrsNoel Grandin
can put SwDataChanged on the stack Change-Id: I6631d04e181e2156184833642abdfab83092da60 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135015 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-26sw content controls, date: add ODT filterMiklos Vajna
Map the Date, DateFormat and DateLanguage UNO properties to: <loext:content-control loext:date="..." loext:date-format="..." loext:date-rfc-language-tag="..."> And do the opposite on import. Change-Id: I16d3f755d77ed20380d877ba65dfe6d063f2bec2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134977 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-25directly instantiate IndexedPropertyValuesContainerNoel Grandin
without the overhead of the UNO service engine Change-Id: I4a02fda2b3c92a897634374bf72cfffee4f531f8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134923 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-25sw: refactor and create Justify::SnapToGrid()Mark Hung
Move snapt to grid code from SwFntObj::DrawText() to Justify::SnapToGrid() and create a simple unit test case testSnapToGrid. Note that SnapToGrid() is for "Snap to char is on" case. Change-Id: Ib9b3a08c744216e37dd260434700cbf3f079a0fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134707 Tested-by: Jenkins Reviewed-by: Mark Hung <marklh9@gmail.com>
2022-05-25sw: add stub Title impl for SwAuthorFieldMiklos Vajna
It is advertised as a property, but it's not implemented: just avoid the assert fail on inspecting the UNO wrapper. Change-Id: Icd20c0edf543cf5ac435b9dcfdc8542f435ef231 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134936 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-2591 null derefs seen in crashreporting reportCaolán McNamara
Change-Id: I8114f57cf5a5f74b2debac963813dcf6aac1bd0b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134930 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-05-25tdf#149018 a few more "Objects" -> "OLE Objects"Seth Chaiklin
-- part of a general project to use "OLE Object" instead of "Object" in the UI when appropriate. * updated command sequence in one "tip of the day" and converted tip to a question (after preferred style) * title of dialog box for inserting or editing an OLE object Change-Id: I519930c2e95c7a157c43a0870dca8b3df362b65d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134895 Tested-by: Jenkins Reviewed-by: Seth Chaiklin <sdc.blanco@youmail.dk>
2022-05-25sw content controls, date: show a date picker on clickMiklos Vajna
- add a new SwContentControl::GetDateString() that knows how to produce a formatted date, taking the language and the date format into account - add a new SwDateContentControlButton that knows how to open popup a calendar on click and that puts the selected date into SwContentControl::m_oSelectedDate - extend SwWrtShell::GotoContentControl() to consume that selected date & update the document text accordingly - in case SwSelPaintRects::HighlightContentControl() notices a date content control, create an instance of this newly introduced SwDateContentControlButton Change-Id: Ia2cb0fa3aefbf543b8dc2e96bcebb41408eb12c3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134926 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-25Advanced Diagram support: Isolated IDiagramHelper, selection visualizationArmin Le Grand (Allotropia)
Moved and isolated IDiagramHelper to own file to get SdrObjGroup smaller and less dependent again, all places adapted. isDiagram() now available at SdrObject directly, adapted and have less places which need to cast for SdrObjGroup for check. Started to add SdrHdl/selection visualization to seleced Diagram. Only as a start, will need to be extended to look good/better, plus evtl. functionality in handles/UI. Corrected error(s) found by failing UnitTests More clang-notes (static, namespace) I nneeded to follow Change-Id: If4675b3270d3ee30259fce49deb017dbbaf5c0c4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134825 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-05-25tdf#56266 sw xmloff: fix tracked deletions in insertionsLászló Németh
RedlineSuccessorData export, i.e. tracked deletions within tracked insertions were loaded as plain tracked deletions during an ODF roundtrip. After that, e.g. rejecting all changes couldn't reject the lost tracked insertion, keeping the text of the tracked deletion as part of the original text by mistake. Regression from commit a9019e76812a947eb54cfa8d728c19361c929458 "INTEGRATION: CWS oasis (1.3.276); FILE MERGED 2004/05/12 11:00:37 mib 1.3.276.1: - #i20153#: changed <office:annotation> and <office:change-info>" Note: RedlineSuccessorData is still stored in an extra text:insertion within text:changed-region, only the not ODF-compatible office:chg-author and office:chg-date-time attributes were changed to dc:creator and dc:date elements in RedlineSuccessorData export: <text:changed-region> <text:deletion/> <text:insertion/> </text:changed-region> Because this structure still causes a bootstrap ODF validation error in the odfexport and layout tests, check the export with uitest. See also SetChangeInfo()/RedlineAdd(). Change-Id: Ic15c468172bd4d7ea1fd49d9b6610204f23d0036 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134860 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org>
2022-05-25Resolves tdf#146762 - Consistency for list indent and level shortcutsHeiko Tietze
Previously: * Shift + Tab on the first item decreases the indention * Tab on first item increases the indention * Shift + Tab on any item but the first does nothing * Tab on any item but the first demotes the list level * Ctrl + Tab on any item including the first inserts a literal tab New: * Tab on any item demotes the list item (move right) * Shift + Tab on any item demotes the list item (move left) * Ctrl + Tab on any item indents the whole list * Ctrl + Shift + Tab on any item outdents the whole list Change-Id: If64a5103a271d30c10fc903a306c9271e61cae49 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134856 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-05-24comments: reassign ID when copy commentPranam Lashkari
reassigning new ID will make all the comments have unique IDs this will also ensure there is no mixup when working with comments ID Signed-off-by: Pranam Lashkari <lpranam@collabora.com> Change-Id: I94b433130c68354ab94d4d6e9b86751038b31af5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134686 Reviewed-by: Szymon Kłos <szymon.klos@collabora.com> Reviewed-by: Gökay ŞATIR <gokaysatir@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> (cherry picked from commit 0d3bba5c383ef8b9f62c121a26fed4445c813949) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134792 Tested-by: Jenkins
2022-05-24sw XHTML import: handle non-image, non-RTF objects as clickable imagesMiklos Vajna
A pair of XHTML <object> elements is meant to be interpreted as "native data" (outer) and "fallback/preview image" (inner). In practice we map non-PNG + PNG pairs to images and OLE2 data + PNG pairs to OLE2 embedded objects. This setup works for OLE2 data and images, but XHTML producers can also put other raw data to the outer <object> like PDF, DOCX, XLSX, etc. These were mapped to ODummyEmbeddedObject, which preserves data, but you can't interact with the data. Fix the lack of interaction by changing how non-OLE2, non-image data is handled: map them to images where the image has a URL to the native data. This way the OS running Writer can decide how to handle that data. This required changing some existing tests where the intention was to have simple test data for OLE2 data, but that data was not OLE2, so the resulting doc model had images, but embedded objects were expected. Such tests now have OLE2 data instead. Change-Id: I0287ce2d9a02904e28cef619ff9f6e1f354d6147 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134874 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-05-24sw: fix mysterious layout loop in CppunitTest_sw_uiwriter3 testTdf104649Michael Stahl
This didn't happen with master from a week ago on Fedora 35, but happens with Monday's master on Fedora 36. Also happens with libreoffice-7-3 branch. Fundamentally the problem with the bugdoc is that there are tables in footnotes, which aren't really supported and can't split across pages like they would need to. The loop happens because a footnote on page 48 invalidates position of its anchor frame 549 on page 45. This is probably pointless, let's only invalidate if the anchor is on the same page (it should be on the same page, but probably the tables in other footnotes get in the way). Change-Id: I87976c7f8b35725bc8e642133bebb396d37ff0be Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134877 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2022-05-24Use o3tl::make_unsigned in some placesStephan Bergmann
...where a signed and an unsigned value are compared, and the signed value has just been proven to be non-negative here Change-Id: I20600d61a5d59d739bc1bee838c0038e4611aec2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134875 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2022-05-24sw content controls, date: add doc model & UNO APIMiklos Vajna
This is meant to be a content control (providing rich text), which also has a dropdown-like date picker button. Add a new Date property to track this type, together with date format and date language. This should be enough for the UI to generate a correct date string when the file picker is used. Change-Id: If5d46a804d771e903a688fd73cfaf2d2809b7ab9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134847 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-24modernize and improve PropertySetInfoNoel Grandin
(*) use o3tl::span for the array param, which means we don't need a null entry to terminate the array (*) use std::unordered_map to speed things up (*) mark the array as static at a few more call sites Change-Id: I05b6cae7552f44459e183ec05cb94e60edb3bfe0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134832 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-24tdf#149186: Table of contents editor not showing buttons in Dutch UICaolán McNamara
an alternative approach that doesn't leave things too wide for the English UI Change-Id: I17d87702fcf49e593e87710bde44c1a2cba14a86 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134861 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-05-24tdf#149198: sw_ooxmlexport16: Add unittestXisco Fauli
Change-Id: I62360e7e3f3cbf28119102baf566b4c647103c0d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134812 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>