Type definitions and basic operations for text annotations
Provides:
- Annotation type definitions with all properties
- Coordinate system constants
- Creation and destruction functions
- Basic validation functions
Variables
| Type |
Visibility | Attributes |
|
Name |
| Initial | |
|
integer,
|
public, |
parameter
|
:: |
COORD_DATA |
= |
1 |
|
|
integer,
|
public, |
parameter
|
:: |
COORD_FIGURE |
= |
2 |
|
|
integer,
|
public, |
parameter
|
:: |
COORD_AXIS |
= |
3 |
|
Derived Types
Components
| Type |
Visibility | Attributes |
|
Name |
| Initial | |
|
real(kind=wp),
|
public |
|
:: |
r |
= |
0.0_wp |
|
|
real(kind=wp),
|
public |
|
:: |
g |
= |
0.0_wp |
|
|
real(kind=wp),
|
public |
|
:: |
b |
= |
0.0_wp |
|
|
real(kind=wp),
|
public |
|
:: |
a |
= |
1.0_wp |
|
Components
| Type |
Visibility | Attributes |
|
Name |
| Initial | |
|
character(len=256),
|
public |
|
:: |
text |
= |
"" |
|
|
real(kind=wp),
|
public |
|
:: |
x |
= |
0.0_wp |
|
|
real(kind=wp),
|
public |
|
:: |
y |
= |
0.0_wp |
|
|
integer,
|
public |
|
:: |
coord_type |
= |
COORD_DATA |
|
|
logical,
|
public |
|
:: |
validated |
= |
.false. |
|
|
logical,
|
public |
|
:: |
valid |
= |
.true. |
|
|
real(kind=wp),
|
public |
|
:: |
font_size |
= |
12.0_wp |
|
|
real(kind=wp),
|
public |
|
:: |
rotation |
= |
0.0_wp |
|
|
character(len=16),
|
public |
|
:: |
alignment |
= |
'left' |
|
|
character(len=16),
|
public |
|
:: |
ha |
= |
'left' |
|
|
character(len=16),
|
public |
|
:: |
va |
= |
'bottom' |
|
|
character(len=64),
|
public |
|
:: |
font_family |
= |
'DejaVu Sans' |
|
|
character(len=16),
|
public |
|
:: |
weight |
= |
'normal' |
|
|
character(len=16),
|
public |
|
:: |
style |
= |
'normal' |
|
|
real(kind=wp),
|
public |
|
:: |
color(3) |
= |
[0.0_wp, 0.0_wp, 0.0_wp] |
|
|
real(kind=wp),
|
public |
|
:: |
alpha |
= |
1.0_wp |
|
|
logical,
|
public |
|
:: |
has_bbox |
= |
.false. |
|
|
logical,
|
public |
|
:: |
bbox |
= |
.false. |
|
|
type(annotation_color_t),
|
public |
|
:: |
bbox_color |
= |
annotation_color_t(1.0_wp, 1.0_wp, 1.0_wp, 1.0_wp) |
|
|
logical,
|
public |
|
:: |
has_arrow |
= |
.false. |
|
|
real(kind=wp),
|
public |
|
:: |
arrow_x |
= |
0.0_wp |
|
|
real(kind=wp),
|
public |
|
:: |
arrow_y |
= |
0.0_wp |
|
|
integer,
|
public |
|
:: |
arrow_coord_type |
= |
COORD_DATA |
|
|
real(kind=wp),
|
public |
|
:: |
xytext_x |
= |
0.0_wp |
|
|
real(kind=wp),
|
public |
|
:: |
xytext_y |
= |
0.0_wp |
|
|
integer,
|
public |
|
:: |
xytext_coord_type |
= |
COORD_DATA |
|
|
character(len=64),
|
public |
|
:: |
arrowstyle |
= |
'' |
|
Functions
Create a text annotation with specified properties
Arguments
| Type |
Intent | Optional | Attributes |
|
Name |
|
|
character(len=*),
|
intent(in) |
|
|
:: |
text |
|
|
real(kind=wp),
|
intent(in) |
|
|
:: |
x |
|
|
real(kind=wp),
|
intent(in) |
|
|
:: |
y |
|
|
integer,
|
intent(in), |
optional |
|
:: |
coord_type |
|
Subroutines
Clean up text annotation resources
Arguments
| Type |
Intent | Optional | Attributes |
|
Name |
|
|
type(text_annotation_t),
|
intent(inout) |
|
|
:: |
annotation |
|
Validate annotation coordinate values
Arguments
| Type |
Intent | Optional | Attributes |
|
Name |
|
|
type(text_annotation_t),
|
intent(in) |
|
|
:: |
annotation |
|
|
logical,
|
intent(out) |
|
|
:: |
valid |
|
|
character(len=256),
|
intent(out) |
|
|
:: |
error_message |
|
Validate annotation parameter values
Arguments
| Type |
Intent | Optional | Attributes |
|
Name |
|
|
type(text_annotation_t),
|
intent(in) |
|
|
:: |
annotation |
|
|
logical,
|
intent(out) |
|
|
:: |
valid |
|
|
character(len=256),
|
intent(out) |
|
|
:: |
error_message |
|
Comprehensive annotation validation combining coordinate and parameter checks
Arguments
| Type |
Intent | Optional | Attributes |
|
Name |
|
|
type(text_annotation_t),
|
intent(in) |
|
|
:: |
annotation |
|
|
logical,
|
intent(out) |
|
|
:: |
valid |
|
|
character(len=*),
|
intent(out) |
|
|
:: |
error_message |
|