summaryrefslogtreecommitdiffstats
path: root/static/logo
diff options
context:
space:
mode:
Diffstat (limited to 'static/logo')
-rw-r--r--static/logo/peach.pngbin11642 -> 11617 bytes
-rw-r--r--static/logo/peach.rkt23
2 files changed, 15 insertions, 8 deletions
diff --git a/static/logo/peach.png b/static/logo/peach.png
index f47deb6..3673d06 100644
--- a/static/logo/peach.png
+++ b/static/logo/peach.png
Binary files differ
diff --git a/static/logo/peach.rkt b/static/logo/peach.rkt
index cfd6e11..98e01e0 100644
--- a/static/logo/peach.rkt
+++ b/static/logo/peach.rkt
@@ -13,18 +13,25 @@
(send dc set-brush "black" 'solid))
;; Draws a moon.
-(define (moon-drawing)
- (let ((moon (new dc-path%)))
- (send moon arc -50 50 320 320 1.57 4.36 #f)
- (send moon arc 1 4 490 490 3.54 2.20 #t)
+(define (moon-drawing size)
+ (let* ((moon (new dc-path%))
+ (inner-arc-x (/ (* size -50) 500.0))
+ (inner-arc-y (* -1 inner-arc-x))
+ (inner-arc-size (/ (* size 320) 500.0))
+ (outer-arc-x (/ (* size 5) 500.0))
+ (outer-arc-y outer-arc-x)
+ (outer-arc-size (/ (* size 490) 500.0)))
+ (send moon arc inner-arc-x inner-arc-y inner-arc-size inner-arc-size 1.57 4.36 #f)
+ (send moon arc outer-arc-x outer-arc-y outer-arc-size outer-arc-size 3.54 2.20 #t)
moon))
;; Draws the peach logo in a bitmap and returns the bitmap.
-(define (draw-logo)
- (let* ((target (make-bitmap 500 500))
+(define (draw-logo size)
+ (let* ((target (make-bitmap size size))
(dc (new bitmap-dc% (bitmap target))))
(setup-dc dc)
- (send dc draw-path (moon-drawing))
+ (send dc set-brush "black" 'solid)
+ (send dc draw-path (moon-drawing size))
target))
;; Exports the logo into PNG.
@@ -32,7 +39,7 @@
(send logo save-file "peach.png" 'png))
;; Peach logo as a bitmap.
-(define peach-logo (draw-logo))
+(define peach-logo (draw-logo 500))
;; Render logo in racket shell.
(make-object image-snip% peach-logo)