| 1 | package CXC::Gnuplot::V0::AxisTics; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 2 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 3 | 1 | ▶ | use v5.38; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 4 | 1 | ▶ | use experimental 'builtin', 'declared_refs'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 5 | 1 | ▶ | use Feature::Compat::Class; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 6 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 7 | 1 | our $VERSION = 'v0.29.3'; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 8 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 9 | class CXC::Gnuplot::V0::AxisTics; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 10 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 11 | 1 | ▶ | use builtin 'is_bool', 'true', 'false'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 12 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 13 | 1 | ▶ | no namespace::clean; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 14 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 15 | 1 | ▶ | use Ref::Util 'is_plain_hashref', 'is_plain_arrayref', 'is_ref'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 16 | 1 | ▶ | use List::Util 'none'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 17 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 18 | 1 | ▶ | use namespace::clean; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 19 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 20 | 1 | use CXC::Gnuplot::V0::Types -lexical, qw( | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 21 | Enum | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 22 | is_Num | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 23 | is_NonEmptyStr | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 24 | PerlBoolFalse | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 25 | TicList | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 26 | TicSeries | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 27 | CoordOffset3D | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 28 | 1 | ▶ | ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 29 | 1 | use CXC::Gnuplot::V0::Util -lexical, 'maybe_quote', 'assert_coerce_object', 'clone_object', | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 30 | 1 | ▶ | 'pvalidate', 'to_hash_r', 'render_opts'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 31 | 1 | ▶ | use CXC::Gnuplot::V0::AxisFormat; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 32 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 33 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 34 | my sub croak { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 35 | 0 | ▶ | require Carp; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
croak: not called CC=1 SCAR=6.9
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 36 | 0 | goto \&Carp::croak; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 37 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 38 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 39 | #<<< no tidy | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 40 | 1 | field $where :param :reader = undef; # {axis | border} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 41 | 1 | field $mirror :param :reader = undef; # {{no}mirror} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 42 | 1 | field $direction :param :reader = undef; # {in |out} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 43 | 1 | field $scale :param :reader = undef; # {scale {default | <major> {,<minor>}}} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 44 | 1 | field $rotate :param :reader = undef; # {{no}rotate {by <ang>}} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 45 | 1 | field $offset :param :reader = undef; # {offset <offset> | nooffset} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 46 | 1 | field $justify :param :reader = undef; # {left | right | center | autojustify} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 47 | 1 | field $positions :param :reader = undef; # { autofreq | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 48 | # | <incr> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 49 | # | <start>, <incr> {,<end>} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 50 | # | ({"<label>"} <pos> {<level>} {,{"<label>"}...) } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 51 | 1 | field $format :param :reader = undef; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 52 | 1 | field $font :param :reader = undef; # {"name{,<size>}"} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 53 | 1 | field $enhanced :param :reader = undef; # {{no}enhanced} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 54 | 1 | field $logscale :param :reader = undef; #{{no}logscale} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 55 | 1 | field $rangelimited :param :reader = undef; # {rangelimited} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 56 | 1 | field $textcolor :param :reader = undef; # {colorspec} | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 57 | #>>> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 58 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 59 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 60 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 61 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 62 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 63 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 64 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 65 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 66 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 67 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 68 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 69 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 70 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 71 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 72 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 73 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 74 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 75 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 76 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 77 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 78 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 79 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 80 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 81 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 82 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 83 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 84 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 85 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 86 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 87 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 88 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 89 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 90 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 91 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 92 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 93 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 94 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 95 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 96 | ADJUST { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 97 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 98 | 0 | ▶ | pvalidate( where => Enum->of( 'axis', 'border' ), \$where ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
__ANON__: not called CC=14 SCAR=53.5
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 99 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 100 | 0 | ▶ | defined $mirror | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
defined $mirror and not builtin::is_bool($mirror)
MC/DC0%0/2
defined $mirror and not builtin::is_bool($mirror)
defined $mirror
not builtin::is_bool($mirror)
Truth table0%0/3
A and not(B)
A= defined $mirrorB= not builtin::is_bool($mirror)
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 101 | and !is_bool( $mirror ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 102 | and croak( q{invalid value for "mirror" parameter: must be bool} ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 103 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 104 | 0 | pvalidate( direction => Enum->of( 'axis', 'border' ), \$direction ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 105 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 106 | # for now, just store this as a string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 107 | 0 | ▶ | defined $scale | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
defined $scale and not is_NonEmptyStr($scale)
MC/DC0%0/2
defined $scale and not is_NonEmptyStr($scale)
defined $scale
not is_NonEmptyStr($scale)
Truth table0%0/3
A and not(B)
A= defined $scaleB= not is_NonEmptyStr($scale)
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 108 | and !is_NonEmptyStr( $scale ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 109 | and croak( q{"scale" must be non-empty} ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 110 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 111 | 0 | ▶ | defined $rotate | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/6
defined $rotate and not builtin::is_bool($rotate) and not is_Num $rotate
defined $rotate and not builtin::is_bool($rotate)
MC/DC0%0/3
defined $rotate and not builtin::is_bool($rotate) and not is_Num $rotate
defined $rotate
not builtin::is_bool($rotate)
not is_Num $rotate
Truth table0%0/4
A and not(B) and not(C)
A= defined $rotateB= not builtin::is_bool($rotate)C= not is_Num $rotate
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 112 | and !is_bool( $rotate ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 113 | and !is_Num( $rotate ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 114 | and croak( '"rotate" must be a float or a boolean' ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 115 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 116 | # offset is either a false boolean or an expression | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 117 | 0 | pvalidate( offset => PerlBoolFalse | CoordOffset3D, \$offset ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 118 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 119 | 0 | pvalidate( justify => Enum->of( 'left', 'right', 'center', 'autojustify' ), \$justify ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 120 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 121 | 0 | pvalidate( positions => Enum->of( 'autofreq' ) | TicSeries | TicList, \$positions ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 122 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 123 | 0 | pvalidate( format => AxisFormat => \$format ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 124 | 0 | pvalidate( font => Font => \$font ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 125 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 126 | 0 | ▶ | defined $enhanced | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
defined $enhanced and not builtin::is_bool($enhanced)
MC/DC0%0/2
defined $enhanced and not builtin::is_bool($enhanced)
defined $enhanced
not builtin::is_bool($enhanced)
Truth table0%0/3
A and not(B)
A= defined $enhancedB= not builtin::is_bool($enhanced)
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 127 | and !is_bool( $enhanced ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 128 | and croak( q{invalid value for "enhanced" parameter: must be bool} ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 129 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 130 | 0 | ▶ | defined $logscale | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
defined $logscale and not builtin::is_bool($enhanced)
MC/DC0%0/2
defined $logscale and not builtin::is_bool($enhanced)
defined $logscale
not builtin::is_bool($enhanced)
Truth table0%0/3
A and not(B)
A= defined $logscaleB= not builtin::is_bool($enhanced)
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 131 | and !is_bool( $enhanced ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 132 | and croak( q{invalid value for "logscale" parameter: must be bool} ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 133 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 134 | 0 | ▶ | defined $rangelimited | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
Condition0%0/3
defined $rangelimited and not builtin::is_bool($rangelimited)
MC/DC0%0/2
defined $rangelimited and not builtin::is_bool($rangelimited)
defined $rangelimited
not builtin::is_bool($rangelimited)
Truth table0%0/3
A and not(B)
A= defined $rangelimitedB= not builtin::is_bool($rangelimited)
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 135 | and !is_bool( $rangelimited ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 136 | and croak( q{invalid value for "rangelimited" parameter: must be bool} ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 137 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 138 | 0 | pvalidate( textcolor => ColorSpec => \$textcolor ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 139 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 140 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 141 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 142 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 143 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 144 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 145 | method to_hash { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 146 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 147 | 0 | ▶ | to_hash_r( { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
to_hash: not called CC=15 SCAR=54.8
Pod
documented
Branch: 14 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 148 | ( defined $where ? ( where => $where ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 149 | ( defined $mirror ? ( mirror => $mirror ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 150 | ( defined $direction ? ( direction => $direction ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 151 | ( defined $scale ? ( scale => $scale ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 152 | ( defined $rotate ? ( rotate => $rotate ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 153 | ( defined $offset ? ( offset => $offset ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 154 | ( defined $justify ? ( justify => $justify ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 155 | ( defined $positions ? ( positions => $positions ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 156 | ( defined $enhanced ? ( enhanced => $enhanced ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 157 | ( defined $logscale ? ( logscale => $logscale ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 158 | ( defined $rangelimited ? ( rangelimited => $rangelimited ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 159 | ( defined $textcolor ? ( textcolor => $textcolor ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 160 | ( defined $format ? ( format => $format ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 161 | ( defined $font ? ( font => $font ) : () ), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 162 | } ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 163 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 164 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 165 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 166 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 167 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 168 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 169 | ▶ | sub assert_coerce( $class, $args ) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
assert_coerce: not called CC=1 SCAR=6.9
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 170 | 0 | assert_coerce_object( $class, $args ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 171 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 172 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 173 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 174 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 175 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 176 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 177 | ▶ | method clone ( %args ) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
clone: not called CC=1 SCAR=6.9
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 178 | 0 | return clone_object( $self, \%args ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 179 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 180 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 181 | ▶ | my sub opts_tic_series( $series ) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
opts_tic_series: not called CC=5 SCAR=34.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 182 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 183 | 0 | my \%series = $series; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 184 | 0 | my @position; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 185 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 186 | push @position, $series{start} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 187 | 0 | ▶ | if defined $series{start}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 188 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 189 | 0 | ▶ | if ( defined( my $incr = $series{incr} ) ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 190 | push @position, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 191 | is_plain_hashref( $incr ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 192 | 0 | ▶ | ? join( q{ }, grep defined, $incr->@{ 'multiple', 'unit' } ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 193 | : $incr; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 194 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 195 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 196 | push @position, $series{end} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 197 | 0 | ▶ | if defined $series{end}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 198 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 199 | 0 | return join( ', ', @position ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 200 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 201 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 202 | ▶ | my sub opts_tic_entry ( $entry ) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
opts_tic_entry: not called CC=3 SCAR=24.8
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 203 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 204 | 0 | my \%entry = $entry; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 205 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 206 | 0 | my @pos; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 207 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 208 | defined $entry{label} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 209 | 0 | ▶ | and push @pos, maybe_quote( $entry{label} ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 210 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 211 | 0 | push @pos, $entry{pos}; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 212 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 213 | defined $entry{level} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 214 | 0 | ▶ | and push @pos, $entry{level}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 215 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 216 | 0 | return join q{ }, @pos; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 217 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 218 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 219 | ▶ | my sub opts_positions ( $positions ) { | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
opts_positions: not called CC=5 SCAR=34.0
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 220 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 221 | 0 | ▶ | return () if !defined $positions; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 222 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 223 | # start, incr, end | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 224 | 0 | ▶ | return opts_tic_series( $positions ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 225 | if is_plain_hashref( $positions ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 226 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 227 | # autofreq | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 228 | 0 | ▶ | return $positions if !is_plain_arrayref( $positions ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 229 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 230 | 0 | my \@positions = $positions; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 231 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 232 | # add | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 233 | 0 | ▶ | my @add = is_ref( $positions[0] ) ? () : shift @positions; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 234 | 0 | my $tics = join q{, }, map { opts_tic_entry( $_ ) } @positions; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 235 | 0 | return join q{ }, @add, "( $tics )"; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 236 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 237 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 238 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 239 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 240 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 241 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 242 | method opts { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 243 | 0 | ▶ | my @opts; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Subroutine
opts: not called CC=20 SCAR=60.4
Pod
documented
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 244 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 245 | 0 | ▶ | defined $where | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 246 | and push @opts, $where; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 247 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 248 | 0 | ▶ | defined $mirror | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 249 | and push @opts, $mirror ? 'mirror' : 'nomirror'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 250 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 251 | 0 | ▶ | defined $direction | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 252 | and push @opts, $direction; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 253 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 254 | 0 | ▶ | defined $scale | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 255 | and push @opts, [ scale => $scale ]; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 256 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 257 | 0 | ▶ | defined $rotate | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 3 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 258 | and push @opts, is_bool( $rotate ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 259 | ? ( $rotate ? 'rotate' : 'norotate' ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 260 | : [ 'rotate by' => $rotate ]; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 261 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 262 | 0 | ▶ | if ( defined $offset ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 263 | 0 | ▶ | if ( is_bool( $offset ) ) { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 264 | 0 | ▶ | push @opts, ( $offset ? 'offset' : 'nooffset' ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 265 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 266 | else { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 267 | 0 | push @opts, render_opts( offset => $offset ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 268 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 269 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 270 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 271 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 272 | 0 | ▶ | defined $justify | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 273 | and push @opts, $justify; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 274 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 275 | 0 | ▶ | defined $positions | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 276 | and push @opts, opts_positions( $positions ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 277 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 278 | 0 | push @opts, render_opts( format => $format ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 279 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 280 | 0 | push @opts, render_opts( font => $font ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 281 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 282 | 0 | ▶ | defined $enhanced | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 283 | and push @opts, ( $enhanced ? 'enhanced' : 'noenhanced' ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 284 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 285 | 0 | ▶ | defined $logscale | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 286 | and push @opts, ( $logscale ? 'logscale' : 'nologscale' ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 287 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 288 | 0 | ▶ | defined $rangelimited | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 289 | and push @opts, ( $rangelimited ? 'rangelimited' : () ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 290 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 291 | 0 | push @opts, render_opts( textcolor => $textcolor ); | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 292 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 293 | 0 | return @opts; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 294 | } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 295 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 296 | # | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 297 | # This file is part of CXC-Gnuplot | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 298 | # | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 299 | # This software is Copyright (c) 2024 by Smithsonian Astrophysical Observatory. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 300 | # | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 301 | # This is free software, licensed under: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 302 | # | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 303 | # The GNU General Public License, Version 3, June 2007 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 304 | # | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 305 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 306 | 1 | 1; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 307 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 308 | __END__ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||