summaryrefslogtreecommitdiff
path: root/docmodel
AgeCommit message (Collapse)AuthorFilesLines
2024-07-16cid#1554709 COPY_INSTEAD_OF_MOVECaolán McNamara1-1/+1
and cid#1554745 COPY_INSTEAD_OF_MOVE cid#1554758 COPY_INSTEAD_OF_MOVE cid#1554766 COPY_INSTEAD_OF_MOVE cid#1554771 COPY_INSTEAD_OF_MOVE cid#1554787 COPY_INSTEAD_OF_MOVE cid#1554802 COPY_INSTEAD_OF_MOVE cid#1554820 COPY_INSTEAD_OF_MOVE cid#1554828 COPY_INSTEAD_OF_MOVE cid#1554829 COPY_INSTEAD_OF_MOVE cid#1554832 COPY_INSTEAD_OF_MOVE cid#1554842 COPY_INSTEAD_OF_MOVE cid#1554885 COPY_INSTEAD_OF_MOVE Change-Id: I43ec20250a04dc087f3d7fdeafc75f0c1dd0de25 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170542 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-09cid#1557551 Use of auto that causes a copyCaolán McNamara1-1/+1
Change-Id: Id3b31e1a5ca54f6bc3c61ad325f37bb6896dc760 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170200 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-05-20loplugin:ostr in variousNoel Grandin1-6/+6
Change-Id: I9f399b3752da9df930e0647536ffcd4e82beb1ac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167856 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-03-04cool#8327 use tools::JsonWriter for theme colorsNoel Grandin1-11/+8
Change-Id: Iebca3781910f9e28100258da8266d51f673f31d8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164232 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-09-23tdf#146619 Recheck include/d* with IWYUGabor Kelemen1-0/+1
Change-Id: Ib17953b49e5035255203e33778a262211d1491f7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156985 Tested-by: Jenkins Reviewed-by: Gabor Kelemen <kelemeng@ubuntu.com>
2023-08-21move BGradient to awt::Gradient2 UNO conversion into docmodelTomaž Vajngerl2-0/+202
This is needed because the module dependencies are an issues if the conversion is done in basegfx. The bigger issue will come when the ComplexColor conversion will be done as basegfx can't depend on docmodel because of circular dependencies. The BGradient is also more suitable for docmodel anyway as the previously it was part of the model and is not a basic (gfx) type - however this doesn't move the whole BGradient into docmodel yet. Change-Id: Id91ce52232f89f00e09b451c13da36e2854ae14b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155674 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-08-15ComplexColor various clean-up and (trivial) refactoringsTomaž Vajngerl4-8/+6
Don't allow access to member variables of ComplexColor and makes them private. Needs a lot of changes. Change "scheme" to "theme" to be more consistent. In LO we usually call the "theme color" what is usually refered to as "scheme color" in OOXML, where it is sometimes refered to as "scheme" and other times as theme color. Remove ThemeColor class which was replaced with CmplexColor some time ago. Remove un-needed includes and un-needed components. Use isValidThemeColor in many places where we check that the ComplexColor is of "Theme" type and that ThemeColorType is set to a valid value. Change-Id: I325595fa65b8e56a4707e9d22acc6330aac28961 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155359 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-06-09fix wrong transform type, error handling when JSON parsingTomaž Vajngerl1-25/+27
also fix theme export - change scheme enum type name "hlink" to "hyperlink" and "folHlink" to "followedHyperlink" Change-Id: Id5435d59cd51352efc4a4a8e333ec1ff45847a6f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152782 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-06-05lok: callback to send the updated theme palette when theme changesTomaž Vajngerl1-6/+9
The callback sends the updated theme color palette when the theme changes or initially when the view is registered, so the client should always have the up-to-date theme color palette stored, so it can just show the color picker with the theme at any time without the need to call the server. Change-Id: I7cceccc46c2fad23ba89e6d3f3643e37f8dab292 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152589 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-05-12change ComplexColor to show more useful propertiesTomaž Vajngerl1-3/+9
Change-Id: Ie19f080f2faf388f9b8ba3e9a4b3c0926d5ebdd4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151674 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-05-12use ComplexColor instead of ThemeColor for better OOXML compat.Tomaž Vajngerl4-64/+11
In OOXML a color definition includes more represenations, one of which is scheme color (which is what is implemented in ThemeColor currently), but it supports other representations too (RGB, HSL, System,..). ComplexColor includes all the representations, so to have a better compatibility with OOXML, this changes all uses of ThemeColor to ComplexColor. In many cases the usage of ComplexColor isn't the same as the usage of ThemeColors, but this cases will need to be changed in a later commit. Change-Id: I9cc8acee2ac0a1998fe9b98247bcf4a96273149a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151492 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-05-09change model::ColorSet to be stored in a shared_ptr in model::ThemeTomaž Vajngerl2-15/+5
Change-Id: Ic3067f1681c047cd944e64179c568f4e972e0c95 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151447 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-05-08svx: use ComplexColor in SvxColorItem instead of the ThemeColorTomaž Vajngerl1-0/+12
ComplexColor includes everything a ThemeColor has and in addition also can have various other representations that are supported by OOXML. This is important for compatibility reasons to preserve the color information. Change-Id: I677775a96511dc1742c75b1949e002eaa8c622e2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151226 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-05-08XComplexColor and UnoComplexColor - a wrapper for model:ComplexColorTomaž Vajngerl2-0/+38
Change-Id: I40107fc38a4d080d969fee862595660d2f585e51 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151225 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-04-24loplugin:unnecessarygetstr extend to more std::string checkingNoel Grandin1-2/+2
suggested by mike kaganski Change-Id: I5f5f254142767aca45a6101abdd84a0163ca6a34 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150936 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-04-08use shared_ptr for model::Theme instead of unique_ptrTomaž Vajngerl1-4/+5
Also change other cases to use the shared_ptr so there is no need to do copies and replace some of docmodel/theme/Theme.hxximports with forward declarations. Change-Id: I4588cb25e05e5f3e535011fffb68a8075b05aecc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147691 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-03-01send theme info when changing color (in the picker) via UNO commandTomaž Vajngerl2-1/+106
Change-Id: I288f8fb3375e152b5ee746fab2c05d08150d6c99 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146817 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-01-31sd: use XTheme to transport the theme to xmloff import/exportTomaž Vajngerl1-0/+2
Refactor the existing places and tests in Impress code (sd) to use it instead. Also keep the old property of construction and view of the theme with a sequence of property values, but under the new property named "ThemeUnoRepresentation". This is needed by the UI tests currently. Change-Id: I484567f4a603f1a5e2e03955fdd2b63132dcc66e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146225 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-01-28introduce XTheme and UnoTheme implementationTomaž Vajngerl3-0/+58
Needed to transprt model::Theme around using throught UNO API as xmloff can't access SdrPage directly. Change-Id: I5931e42352186d62e7f09b112d8e8c9e4fb79440 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146224 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-01-27move Theme class to own file inside docmodelTomaž Vajngerl2-0/+159
Also move Theme from svx to model namespace so it is consistent with other classes in docmodel. Theme header also includes ThemeSupplementalFont, ThemeFont, FontScheme classes that are used by the Theme and were also moved to docmodel. These may be moved to its own file in the future when they are used in more places. Change-Id: Ic409bea8e5298adc2b039b529c4f7b01cf64f03e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146221 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-01-27move ColorSet class to own file inside docmodelTomaž Vajngerl2-0/+79
Also move ColorSet from svx to model namespace so it is consistent with other classes in docmodel. Change-Id: Iacbdbdf5ece4015c628a0e45adf6a732b2d27777 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146220 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-01-13Fix typosAndrea Gelmini1-1/+1
Change-Id: I173920a96524f991f2965af99e8d95f11d1b3c35 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145455 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2023-01-12introduce docmodel comp., model::ThemeColor, use it in SvxColorItemTomaž Vajngerl7-0/+155
Added a new component docmodel, that has the document model types, which only depend on other basic components. This is needed so the types can be used in every relevant component - xmloff, oox, svx, editeng,... Introduces model::ThemeColor, which is a class used to store the theme color data, including transformations (svx::Transformation). For UNO use XThemeColor is added, and the implementation UnoThemeColor which wraps svx::ThemeColor, so it can be tranported around. Reactor all the code and tests to accomodate for this change. Change-Id: I7ce6752cdfaf5e4d3b8e4d90314afa469dd65cfc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144847 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>