-
-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
... to control the amount of space left unused around the plot edge and plot legend.
- Loading branch information
Showing
11 changed files
with
162 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#lang racket | ||
|
||
(require rackunit | ||
plot racket/runtime-path | ||
"../helpers.rkt") | ||
|
||
;; see https://github.com/racket/plot/pull/124 | ||
|
||
(define-runtime-path pr124-data "./test-data/pr124.dat") | ||
|
||
(define (do-plot-pr124 output-fn) | ||
(parameterize | ||
([plot-line-width 15] | ||
[line-width 15] | ||
[plot-inset '(0 10 10 0)] | ||
[plot-pen-color-map 'set1] | ||
[plot-legend-padding '(0 15 0 0)] | ||
[plot-line-cap 'round] | ||
[line-cap 'round]) | ||
(output-fn | ||
(list | ||
(function sin -5 5 #:color 0 #:label "sin(x)") | ||
(function cos -5 5 #:color 1 #:label "cos(x)"))))) | ||
|
||
(define pr124-test-suite | ||
(test-suite | ||
"PR#124: Add plot-inset and plot-legend-padding parameters" | ||
(test-case "pr124" | ||
(check-draw-steps do-plot-pr124 pr124-data)))) | ||
|
||
(module+ test | ||
(require rackunit/text-ui) | ||
(run-tests pr124-test-suite)) |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.