OpenSiv3D  v0.6.5
C++20 framework for creative coding
s3d::TextStyle Struct Reference

テキストのスタイル More...

#include <TextStyle.hpp>

Public Types

enum  Type : uint8 {
  Type::Default, Type::Outline, Type::Shadow, Type::OutlineShadow,
  Type::CustomShader
}
 

Static Public Member Functions

static constexpr TextStyle Default () noexcept
 デフォルトのスタイルを返します。 More...
 
static constexpr TextStyle CustomShader () noexcept
 カスタムシェーダ用のスタイルを返します。 More...
 
static constexpr TextStyle Outline (double p, const ColorF &color) noexcept
 輪郭付きのスタイルを返します。 More...
 
static constexpr TextStyle Outline (double inner, double outer, const ColorF &color) noexcept
 輪郭付きのスタイルを返します。 More...
 
static constexpr TextStyle Shadow (const Vec2 &offset, const ColorF &color) noexcept
 シャドウ付きのスタイルを返します。 More...
 
static constexpr TextStyle OutlineShadow (double p, const ColorF &outlineColor, const Vec2 &offset, const ColorF &shadowColor) noexcept
 輪郭とシャドウ付きのスタイルを返します。 More...
 
static constexpr TextStyle OutlineShadow (double inner, double outer, const ColorF &outlineColor, const Vec2 &offset, const ColorF &shadowColor) noexcept
 輪郭とシャドウ付きのスタイルを返します。 More...
 

Public Attributes

Float4 param = { 0.5f, 0.5f, 0.0f, 0.0f }
 
Float4 outlineColor = { 0.0f, 0.0f, 0.0f, 1.0f }
 
Float4 shadowColor = { 0.0f, 0.0f, 0.0f, 0.5f }
 
enum s3d::TextStyle::Type type = Type::Default
 

Detailed Description

テキストのスタイル

Member Enumeration Documentation

◆ Type

enum s3d::TextStyle::Type : uint8
strong
Enumerator
Default 
Outline 
Shadow 
OutlineShadow 
CustomShader 

Member Function Documentation

◆ CustomShader()

static constexpr TextStyle s3d::TextStyle::CustomShader ( )
staticconstexprnoexcept

カスタムシェーダ用のスタイルを返します。

Returns
カスタムシェーダ用のスタイル

◆ Default()

static constexpr TextStyle s3d::TextStyle::Default ( )
staticconstexprnoexcept

デフォルトのスタイルを返します。

Returns
デフォルトのスタイル

◆ Outline() [1/2]

static constexpr TextStyle s3d::TextStyle::Outline ( double  inner,
double  outer,
const ColorF color 
)
staticconstexprnoexcept

輪郭付きのスタイルを返します。

Parameters
inner内側の輪郭の太さを示すパラメータ
outer外側の輪郭の太さを示すパラメータ
color輪郭の色
Returns
輪郭付きのスタイル

◆ Outline() [2/2]

static constexpr TextStyle s3d::TextStyle::Outline ( double  p,
const ColorF color 
)
staticconstexprnoexcept

輪郭付きのスタイルを返します。

Parameters
p輪郭の太さを示すパラメータ
color輪郭の色
Returns
輪郭付きのスタイル

◆ OutlineShadow() [1/2]

static constexpr TextStyle s3d::TextStyle::OutlineShadow ( double  inner,
double  outer,
const ColorF outlineColor,
const Vec2 offset,
const ColorF shadowColor 
)
staticconstexprnoexcept

輪郭とシャドウ付きのスタイルを返します。

Parameters
inner内側の輪郭の太さを示すパラメータ
outer外側の輪郭の太さを示すパラメータ
outlineColor輪郭の色
offsetシャドウのオフセットを示すパラメータ
shadowColorシャドウの色
Returns
輪郭とシャドウ付きのスタイル

◆ OutlineShadow() [2/2]

static constexpr TextStyle s3d::TextStyle::OutlineShadow ( double  p,
const ColorF outlineColor,
const Vec2 offset,
const ColorF shadowColor 
)
staticconstexprnoexcept

輪郭とシャドウ付きのスタイルを返します。

Parameters
p輪郭の太さを示すパラメータ
outlineColor輪郭の色
offsetシャドウのオフセットを示すパラメータ
shadowColorシャドウの色
Returns
輪郭とシャドウ付きのスタイル

◆ Shadow()

static constexpr TextStyle s3d::TextStyle::Shadow ( const Vec2 offset,
const ColorF color 
)
staticconstexprnoexcept

シャドウ付きのスタイルを返します。

Parameters
offsetシャドウのオフセットを示すパラメータ
colorシャドウの色
Returns
シャドウ付きのスタイル

Member Data Documentation

◆ outlineColor

Float4 s3d::TextStyle::outlineColor = { 0.0f, 0.0f, 0.0f, 1.0f }

◆ param

Float4 s3d::TextStyle::param = { 0.5f, 0.5f, 0.0f, 0.0f }

◆ shadowColor

Float4 s3d::TextStyle::shadowColor = { 0.0f, 0.0f, 0.0f, 0.5f }

◆ type

enum s3d::TextStyle::Type s3d::TextStyle::type = Type::Default

The documentation for this struct was generated from the following file: