office-gobmx/include/svx/theme/ThemeColorChangerCommon.hxx
Szymon Kłos 39b5a39bdc Send document colors with lok callback
First step for publishing any palette for LOK.
Let's start with Document colors (colors used in the
document) which can be extracted similar to theme
colors from SfxViewShell.

Modify generateJSON function so it appends palette into
existing ptree/JSON.

In the next step we can make it more generic so it will
be able to send any palette managed by PaletteManager.

Change-Id: Ibb56690af6dfd59ee232e88b28e7a3d312d0e16c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161798
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 0460be8848)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161941
Tested-by: Jenkins
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
2024-01-12 13:58:22 +01:00

33 lines
1,014 B
C++

/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
#pragma once
#include <set>
#include <svx/svxdllapi.h>
#include <docmodel/theme/ColorSet.hxx>
#include <svx/svdobj.hxx>
#include <svx/svdview.hxx>
#include <svl/undo.hxx>
namespace svx
{
namespace theme
{
SVXCORE_DLLPUBLIC void updateSdrObject(model::ColorSet const& rColorSet, SdrObject* pObject,
SdrView* pView, SfxUndoManager* pUndoManager = nullptr);
/// Sends to the LOK updated palettes
SVXCORE_DLLPUBLIC void notifyLOK(std::shared_ptr<model::ColorSet> const& pColorSet,
const std::set<Color>& rDocumentColors);
}
} // end svx namespace
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */