Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
testbed-manual
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
emulab
testbed-manual
Commits
1039488b
Commit
1039488b
authored
Jun 11, 2014
by
Robert Ricci
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Break out screenshot into a function that can be used by itself
parent
f566cdf9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
7 deletions
+11
-7
defs.rkt
defs.rkt
+11
-7
No files found.
defs.rkt
View file @
1039488b
...
...
@@ -28,14 +28,18 @@
(
string-append
(
number->string
howmany
)
" nodes"
))
properties
))))
(
define
(
instructionstep
step
#:screenshot
[
screenshot
#f
]
.
body
)
(
define
(
screenshot
path
)
(
let*
([
fullpath
(
string-append
"screenshots/"
path
)]
[
b
(
make-object
bitmap%
fullpath
)]
[
width
(
send
b
get-width
)]
[
scale-factor
(
/
screenshot-width
width
)])
(
list
(
image
#:scale
scale-factor
fullpath
fullpath
)
(
linebreak
))))
(
define
(
instructionstep
step
#:screenshot
[
screenshot-path
#f
]
.
body
)
(
item
(
bold
(
decode-content
(
list
step
)))
(
linebreak
)
(
if
screenshot
(
let*
([
path
(
string-append
"screenshots/"
screenshot
)]
[
b
(
make-object
bitmap%
path
)]
[
width
(
send
b
get-width
)]
[
scale-factor
(
/
screenshot-width
width
)])
(
list
(
image
#:scale
scale-factor
path
screenshot
)
(
linebreak
)))
(
if
screenshot-path
(
screenshot
screenshot-path
)
(
void
))
(
decode-content
body
)))
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment