# Description: Tests for various pline functions.

test pline-1.1 {pline coords} \
-setup ::tkp_setup \
-result {200 201 250 202} \
-body {
    lassign [.c coords [.c create pline 200 201 250 202]] l t r b
    return [list \
               [expr { round($l) }] \
               [expr { round($t) }] \
               [expr { round($r) }] \
               [expr { round($b) }]]

}

test pline-1.2 {pline {coords after move}} \
-setup ::tkp_setup \
-result {220 221 270 222} \
-body {
    set pline [.c create pline 200 201 250 202]
    .c move $pline 20 20
    lassign [.c coords $pline] l t r b
    return [list \
               [expr { round($l) }] \
               [expr { round($t) }] \
               [expr { round($r) }] \
               [expr { round($b) }]]

}

test pline-1.3 {pline {Strokedash as .}} \
-setup ::tkp_setup \
-result {} \
-body {
    set pline [.c create pline 200 201 250 202 \
                  -strokedasharray {0.1 0.2}]
    return {}
}

# cleanup
::tkp_cleanup
return
