LeechCraft
0.6.70-16373-g319c272718
Modular cross-platform feature rich live environment.
fontsizescrollchanger.h
Go to the documentation of this file.
1
/**********************************************************************
2
* LeechCraft - modular cross-platform feature rich internet client.
3
* Copyright (C) 2006-2014 Georg Rudoy
4
*
5
* Distributed under the Boost Software License, Version 1.0.
6
* (See accompanying file LICENSE or copy at https://www.boost.org/LICENSE_1_0.txt)
7
**********************************************************************/
8
9
#pragma once
10
11
#include <functional>
12
#include <variant>
13
#include "
guiconfig.h
"
14
15
class
QWidget;
16
class
QFont;
17
18
namespace
LC::Util
19
{
20
template
<
typename
T>
21
struct
FontSizeChangerMethods
22
{
23
std::function<T ()>
GetView_
;
24
std::function<void (T)>
SetView_
;
25
std::function<void (T)>
SetDefault_
;
26
};
27
28
using
PixelBasedParams
=
FontSizeChangerMethods<int>
;
29
using
FontBasedParams
=
FontSizeChangerMethods<QFont>
;
30
31
using
FontSizeChangerParams
= std::variant<PixelBasedParams, FontBasedParams>;
32
33
UTIL_GUI_API
void
InstallFontSizeChanger
(QWidget&,
const
FontSizeChangerParams
&);
34
}
LC::Util::FontSizeChangerMethods::SetView_
std::function< void(T)> SetView_
Definition:
fontsizescrollchanger.h:24
LC::Util::FontSizeChangerMethods
Definition:
fontsizescrollchanger.h:21
UTIL_GUI_API
#define UTIL_GUI_API
Definition:
guiconfig.h:16
LC::Util::FontSizeChangerMethods::SetDefault_
std::function< void(T)> SetDefault_
Definition:
fontsizescrollchanger.h:25
LC::Util::FontSizeChangerMethods::GetView_
std::function< T()> GetView_
Definition:
fontsizescrollchanger.h:23
guiconfig.h
LC::Util
Definition:
icoreproxy.h:33
LC::Util::FontSizeChangerParams
std::variant< PixelBasedParams, FontBasedParams > FontSizeChangerParams
Definition:
fontsizescrollchanger.h:31
LC::Util::InstallFontSizeChanger
void InstallFontSizeChanger(QWidget &widget, const FontSizeChangerParams ¶ms)
Definition:
fontsizescrollchanger.cpp:35
src
util
gui
fontsizescrollchanger.h
Generated by
1.8.14