xtd - Reference Guide  0.2.0
Modern c++17/20 framework to create console, GUI and unit test applications on Windows, macOS, Linux, iOS and android.
image_format.h
Go to the documentation of this file.
1 #pragma once
5 #include <cstdint>
6 #include <ostream>
7 #include <string>
8 #include <xtd/guid.h>
9 #include <xtd/object.h>
10 #include <xtd/ustring.h>
11 
13 namespace xtd {
15  namespace drawing {
18  namespace imaging {
25  class image_format final : public object {
26  public:
28  image_format() = default;
30 
34  explicit image_format(const guid& guid) : guid_(guid) {}
35 
37  image_format(const image_format&) = default;
38  image_format& operator=(const image_format&) = default;
39  bool operator==(const image_format& value) const {return guid_ == value.guid_;}
40  bool operator!=(const image_format& value) const {return !operator==(value);}
41  bool operator<(const image_format& value) const {return guid_ < value.guid_;}
42  bool operator<=(const image_format& value) const {return guid_ <= value.guid_;}
43  bool operator>(const image_format& value) const {return guid_ > value.guid_;}
44  bool operator>=(const image_format& value) const {return guid_ >= value.guid_;}
46 
49  const xtd::guid guid() const {return guid_;}
50 
53  static image_format bmp() {return image_format(xtd::guid("b96b3cab-0728-11d3-9d7b-0000f81ef32e"));}
54 
57  static image_format emf() {return image_format(xtd::guid("b96b3cac-0728-11d3-9d7b-0000f81ef32e"));}
58 
61  static image_format exif() {return image_format(xtd::guid("b96b3cb2-0728-11d3-9d7b-0000f81ef32e"));}
62 
65  static image_format gif() {return image_format(xtd::guid("b96b3cb0-0728-11d3-9d7b-0000f81ef32e"));}
66 
69  static image_format ico() {return image_format(xtd::guid("b96b3cb5-0728-11d3-9d7b-0000f81ef32e"));}
70 
73  static image_format jpeg() {return image_format(xtd::guid("b96b3cae-0728-11d3-9d7b-0000f81ef32e"));}
74 
77  static image_format memory_bmp() {return image_format(xtd::guid("b96b3caa-0728-11d3-9d7b-0000f81ef32e"));}
78 
81  static image_format png() {return image_format(xtd::guid("b96b3caf-0728-11d3-9d7b-0000f81ef32e"));}
82 
85  static image_format tiff() {return image_format(xtd::guid("b96b3cb1-0728-11d3-9d7b-0000f81ef32e"));}
86 
89  static image_format wmf() {return image_format(xtd::guid("b96b3cad-0728-11d3-9d7b-0000f81ef32e"));}
90 
93  static image_format memory_gif() {return image_format(xtd::guid("b96b3cb6-0728-11d3-9d7b-0000f81ef32e"));}
94 
97  static image_format memory_ico() {return image_format(xtd::guid("b96b3cb7-0728-11d3-9d7b-0000f81ef32e"));}
98 
101  static image_format memory_jpeg() {return image_format(xtd::guid("b96b3cb8-0728-11d3-9d7b-0000f81ef32e"));}
102 
105  static image_format memory_png() {return image_format(xtd::guid("b96b3cb9-0728-11d3-9d7b-0000f81ef32e"));}
106 
109  static image_format memory_tiff() {return image_format(xtd::guid("b96b3cba-0728-11d3-9d7b-0000f81ef32e"));}
110 
113  static image_format cur() {return image_format(xtd::guid("b96b3cbb-0728-11d3-9d7b-0000f81ef32e"));}
114 
117  static image_format memory_cur() {return image_format(xtd::guid("b96b3cbc-0728-11d3-9d7b-0000f81ef32e"));}
118 
121  static image_format xbm() {return image_format(xtd::guid("b96b3cbd-0728-11d3-9d7b-0000f81ef32e"));}
122 
125  static image_format memory_xbm() {return image_format(xtd::guid("b96b3cbe-0728-11d3-9d7b-0000f81ef32e"));}
126 
129  static image_format xpm() {return image_format(xtd::guid("b96b3cbf-0728-11d3-9d7b-0000f81ef32e"));}
130 
133  static image_format memory_xpm() {return image_format(xtd::guid("b96b3cc0-0728-11d3-9d7b-0000f81ef32e"));}
134 
137  static image_format pnm() {return image_format(xtd::guid("b96b3cc1-0728-11d3-9d7b-0000f81ef32e"));}
138 
141  static image_format memory_pnm() {return image_format(xtd::guid("b96b3cc2-0728-11d3-9d7b-0000f81ef32e"));}
142 
145  static image_format pcx() {return image_format(xtd::guid("b96b3cc3-0728-11d3-9d7b-0000f81ef32e"));}
146 
149  static image_format memory_pcx() {return image_format(xtd::guid("b96b3cc4-0728-11d3-9d7b-0000f81ef32e"));}
150 
153  static image_format pict() {return image_format(xtd::guid("b96b3cc5-0728-11d3-9d7b-0000f81ef32e"));}
154 
157  static image_format memory_pict() {return image_format(xtd::guid("b96b3cc6-0728-11d3-9d7b-0000f81ef32e"));}
158 
161  static image_format icon() {return image_format(xtd::guid("b96b3cc7-0728-11d3-9d7b-0000f81ef32e"));}
162 
165  static image_format memory_icon() {return image_format(xtd::guid("b96b3cc8-0728-11d3-9d7b-0000f81ef32e"));}
166 
169  static image_format cursor() {return image_format(xtd::guid("b96b3cc9-0728-11d3-9d7b-0000f81ef32e"));}
170 
173  static image_format memory_cursor() {return image_format(xtd::guid("b96b3cca-0728-11d3-9d7b-0000f81ef32e"));}
174 
177  static image_format ani() {return image_format(xtd::guid("b96b3ccb-0728-11d3-9d7b-0000f81ef32e"));}
178 
181  static image_format iif() {return image_format(xtd::guid("b96b3ccc-0728-11d3-9d7b-0000f81ef32e"));}
182 
185  static image_format tga() {return image_format(xtd::guid("b96b3ccd-0728-11d3-9d7b-0000f81ef32e"));}
186 
189  xtd::ustring to_string() const noexcept override {return ustring::format("[image_format: {}]", guid_);}
190 
192  friend std::ostream& operator<<(std::ostream& os, const xtd::drawing::imaging::image_format& image_format) noexcept {
193  return os << image_format.to_string();
194  }
196 
197  private:
198  xtd::guid guid_;
199  };
200  }
201  }
202 }
static image_format cur()
Gets the cursor (cur) image format.
Definition: image_format.h:113
xtd::ustring to_string() const noexcept override
Converts this image_format object to a human-readable string.
Definition: image_format.h:189
static image_format memory_jpeg()
Gets the jpeg memory format.
Definition: image_format.h:101
static image_format ani()
Gets the animated file cursor (ani) image format.
Definition: image_format.h:177
static image_format memory_xpm()
Gets the xpm memory.
Definition: image_format.h:133
Specifies the file format of the image. Not inheritable.
Definition: image_format.h:25
static image_format xpm()
Gets the x pixmap (xpm) image format.
Definition: image_format.h:129
static image_format tiff()
Gets the Tagged Image File Format (TIFF) image format.
Definition: image_format.h:85
static image_format ico()
Gets the windows icon (ico) image format.
Definition: image_format.h:69
static image_format memory_png()
Gets the ipng memory format.
Definition: image_format.h:105
static image_format memory_pcx()
Gets the pcx memory.
Definition: image_format.h:149
Contains xtd::guid class.
The xtd namespace contains all fundamental classes to access Hardware, Os, System, and more.
Definition: system_report.h:17
static image_format pnm()
Gets the portable pixmap (pnm) image format.
Definition: image_format.h:137
static image_format exif()
Gets the Exchangeable Image File (Exif) format.
Definition: image_format.h:61
static image_format memory_pnm()
Gets the pnm memory.
Definition: image_format.h:141
Represents text as a sequence of UTF-8 code units.
Definition: ustring.h:48
static image_format emf()
Gets the enhanced metafile (EMF) image format.
Definition: image_format.h:57
static image_format pict()
Gets the apple pict (pict) image format.
Definition: image_format.h:153
static image_format memory_bmp()
Gets the format of a bitmap in memory.
Definition: image_format.h:77
static image_format memory_ico()
Gets the ico memory format.
Definition: image_format.h:97
static image_format wmf()
Gets the Windows metafile (WMF) image format.
Definition: image_format.h:89
static image_format tga()
Gets the truevision targa (tga) image format.
Definition: image_format.h:185
static image_format memory_cur()
Gets the cur memory.
Definition: image_format.h:117
static image_format memory_tiff()
Gets the tiff memory.
Definition: image_format.h:109
static image_format xbm()
Gets the x bitmap (xbm) image format.
Definition: image_format.h:121
static image_format jpeg()
Gets the Joint Photographic Experts Group (JPEG) image format.
Definition: image_format.h:73
static image_format cursor()
Gets the apple cursor) image format.
Definition: image_format.h:169
Contains xtd::ustring class.
static image_format png()
Gets the W3C Portable Network Graphics (PNG) image format.
Definition: image_format.h:81
static image_format gif()
Gets the Graphics Interchange Format (GIF) image format.
Definition: image_format.h:65
Contains xtd::object class.
Supports all classes in the xtd class hierarchy and provides low-level services to derived classes...
Definition: object.h:26
static image_format icon()
Gets the apple icon (pict) image format.
Definition: image_format.h:161
Represents a globally unique identifier (GUID). A GUID is a 128-bit integer (16 bytes) that can be us...
Definition: guid.h:23
static image_format memory_cursor()
Gets the cursor memory.
Definition: image_format.h:173
static image_format memory_icon()
Gets the icon memory.
Definition: image_format.h:165
static image_format memory_pict()
Gets the pict memory.
Definition: image_format.h:157
static ustring format(const ustring &fmt, args_t &&... args)
Writes the text representation of the specified arguments list, to string using the specified format ...
Definition: ustring.h:689
static image_format memory_gif()
Gets the gif memory format.
Definition: image_format.h:93
const xtd::guid guid() const
Gets a guid structure that represents this image_format object.
Definition: image_format.h:49
static image_format pcx()
Gets the pcx (pcx) image format.
Definition: image_format.h:145
static image_format memory_xbm()
Gets the xbm memory.
Definition: image_format.h:125
static image_format iif()
Gets the iif image format.
Definition: image_format.h:181
static image_format bmp()
Gets the bitmap (BMP) image format.
Definition: image_format.h:53
image_format(const guid &guid)
Initializes a new instance of the image_format class by using the specified guid structure.
Definition: image_format.h:34