aboutsummaryrefslogtreecommitdiffstats
path: root/len_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'len_test.go')
-rw-r--r--len_test.go6
1 files changed, 2 insertions, 4 deletions
diff --git a/len_test.go b/len_test.go
index 91b0886..269f90c 100644
--- a/len_test.go
+++ b/len_test.go
@@ -2,15 +2,13 @@ package gui_test
import (
"fmt"
- "image"
"github.com/faiface/gui"
)
func ExampleRelative() {
- var l Length = Relative(0.10) // 10%
- r := image.Rect(0, 0, 100, 100) // 100x100 rectangle
- fmt.Println(l.Px(r))
+ var l gui.Length = gui.Relative(0.10) // 10%
+ fmt.Println(l.Px(100))
// Output:
// 10
}