xtd 1.0.0
Loading...
Searching...
No Matches
system_images_base.hpp
Go to the documentation of this file.
1
4#pragma once
6#include "bitmap.hpp"
7#include "size.hpp"
8#include <xtd/static>
9#include <xtd/target_id>
10#include <map>
11
13namespace xtd {
15 namespace drawing {
17 class system_icons;
19
33 protected:
35
39 [[nodiscard]] static auto default_size() noexcept -> xtd::drawing::size;
40
60 [[nodiscard]] static auto contexts() noexcept -> xtd::array<xtd::string>;
454 [[nodiscard]] static auto context_names() noexcept -> std::map<xtd::string, xtd::array<xtd::string>>;
847 [[nodiscard]] static auto names() noexcept -> xtd::array<xtd::string>;
1242 [[nodiscard]] static auto names(const xtd::string& context) noexcept -> xtd::array<xtd::string>;
1246 [[nodiscard]] static auto sizes() noexcept -> xtd::array<xtd::drawing::size>;
1248
1250
1257 [[nodiscard]] static auto from_name(const xtd::string& name) -> xtd::drawing::image;
1263 [[nodiscard]] static auto from_name(const xtd::string& name, const xtd::drawing::size& size) -> xtd::drawing::image;
1269 [[nodiscard]] static auto from_name(const xtd::string& theme, const xtd::string& name) -> xtd::drawing::image;
1275 [[nodiscard]] static auto from_name(const xtd::string& theme, const xtd::string& name, const xtd::drawing::size& size) -> xtd::drawing::image;
1277
1278 private:
1279 // This method is only needed to disable the native::system::image::form_name function during unit testing.
1280 [[nodiscard]] static auto native_system_images_from_name_enabled() noexcept -> bool {return __XTD_CURRENT_TARGET_ID__ != __XTD_TARGET_ID_TEST_APPLICATION__;}
1281 friend class system_icons;
1282 [[nodiscard]] static auto default_theme() noexcept -> xtd::string;
1283 [[nodiscard]] static auto fallback_theme() noexcept -> xtd::string;
1284 [[nodiscard]] static auto themes() noexcept -> xtd::array<xtd::string>;
1285 };
1286 }
1287}
1288
Contains xtd::drawing::bitmap class.
Provides methods for creating, manipulating, searching, and sorting arrays, thereby serving as the ba...
Definition array.hpp:64
An abstract base class that provides functionality for the bitmap and metafile descended classes.
Definition image.hpp:49
Each property of the xtd::drawing::system_icons class is an xtd::drawing::icon object for Windows sys...
Definition system_icons.hpp:28
Represents the base for all system_images clases (xtd::drawing::system_images).
Definition system_images_base.hpp:32
static auto names() noexcept -> xtd::array< xtd::string >
Gets the image names.
static auto contexts() noexcept -> xtd::array< xtd::string >
Gets the image contexts.
static auto default_size() noexcept -> xtd::drawing::size
Gets system image from specified name.
static auto sizes() noexcept -> xtd::array< xtd::drawing::size >
Gets standard sizes for image.
static auto context_names() noexcept -> std::map< xtd::string, xtd::array< xtd::string > >
Gets the image context names.
static auto from_name(const xtd::string &name) -> xtd::drawing::image
Gets system image from specified name.
Contains drawing_export_ keyword.
#define drawing_export_
Define shared library export.
Definition drawing_export.hpp:13
#define static_
This keyword is use to represent a static object. A static object can't be instantiated (constructors...
Definition static.hpp:38
The xtd::drawing namespace provides access to GDI+ basic graphics functionality. More advanced functi...
Definition actions_system_images.hpp:10
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8
Contains xtd::drawing::size struct.
Stores an ordered pair of integers, which specify a height and width.
Definition size.hpp:32