Debian Codegraph @

src/scene/x3d/auto_generated_node_helpers/x3dnodes_fontstyle_1.inc

raw
1 { -*- buffer-read-only: t -*-
2
3 Copyright 2015-2024 Michalis Kamburelis.
4
5 This file is part of "Castle Game Engine".
6
7 "Castle Game Engine" is free software; see the file COPYING.txt,
8 included in this distribution, for details about the copyright.
9
10 "Castle Game Engine" is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13
14 ----------------------------------------------------------------------------
15 }
16
17 { Automatically generated node properties.
18
19 Do not edit this file manually!
20 To add new properties:
21 - add them to the text files in tools/internal/x3d-nodes-to-pascal/nodes-specification/ ,
22 - and regenerate include files by running x3d-nodes-to-pascal }
23
24 {$ifdef read_interface}
25
26 strict private
27 function GetSize: Single;
28 procedure SetSize(const Value: Single);
29 function GetBlending: Boolean;
30 procedure SetBlending(const Value: Boolean);
31 public
32 { Create node fields and events. }
33 procedure CreateNode; override;
34 class function ClassX3DType: String; override;
35 class function ForVRMLVersion(const Version: TX3DVersion): Boolean; override;
36
37 strict private FFdSize: TSFFloat;
38 { Internal wrapper for property @code(Size). This wrapper API may change, we advise to access simpler @code(Size) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
39 public property FdSize: TSFFloat read FFdSize;
40 { }
41 property Size: Single read GetSize write SetSize;
42
43 strict private FFdFamily: TSFEnum;
44 { Internal wrapper for property @code(Family). This wrapper API may change, we advise to access simpler @code(Family) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
45 public property FdFamily: TSFEnum read FFdFamily;
46
47 strict private FFdStyle: TSFBitMask;
48 { Internal wrapper for property @code(Style). This wrapper API may change, we advise to access simpler @code(Style) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
49 public property FdStyle: TSFBitMask read FFdStyle;
50
51 strict private FFdBlending: TSFBool;
52 { Internal wrapper for property @code(Blending). This wrapper API may change, we advise to access simpler @code(Blending) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
53 public property FdBlending: TSFBool read FFdBlending;
54 { }
55 property Blending: Boolean read GetBlending write SetBlending;
56
57 {$endif read_interface}
58
59 {$ifdef read_implementation}
60
61 { TFontStyleNode_1 ----------------------------------------------- }
62
63 function TFontStyleNode_1.GetSize: Single;
64 begin
65 Result := FdSize.Value;
66 end;
67
68 procedure TFontStyleNode_1.SetSize(const Value: Single);
69 begin
70 FdSize.Send(Value);
71 end;
72
73 function TFontStyleNode_1.GetBlending: Boolean;
74 begin
75 Result := FdBlending.Value;
76 end;
77
78 procedure TFontStyleNode_1.SetBlending(const Value: Boolean);
79 begin
80 FdBlending.Send(Value);
81 end;
82
83 class function TFontStyleNode_1.ForVRMLVersion(const Version: TX3DVersion): Boolean;
84 begin
85 Result := Version.Major <= 1; // parse this node only in VRML 1.0 and Inventor files
86 end;
87
88 class function TFontStyleNode_1.ClassX3DType: String;
89 begin
90 Result := 'FontStyle';
91 end;
92
93 procedure TFontStyleNode_1.CreateNode;
94 begin
95 inherited;
96
97 FFdSize := TSFFloat.Create(Self, True, 'size', 10);
98 FdSize.ChangeAlways := chGeometryVRML1State;
99 FdSize.MustBeNonnegative := true;
100 AddField(FFdSize);
101
102 FFdFamily := TSFEnum.Create(Self, True, 'family', @FamilyNames1, Ord(High(FamilyNames1)) + 1, FSFAMILY_SERIF);
103 FdFamily.ChangeAlways := chGeometryVRML1State;
104 AddField(FFdFamily);
105
106 FFdStyle := TSFBitMask.Create(Self, True, 'style', ['BOLD', 'ITALIC'], 'NONE', '', [false, false]);
107 FdStyle.ChangeAlways := chGeometryVRML1State;
108 AddField(FFdStyle);
109
110 FFdBlending := TSFBool.Create(Self, True, 'blending', true);
111 FdBlending.ChangeAlways := chGeometryVRML1State;
112 AddField(FFdBlending);
113 end;
114
115 {$endif read_implementation}