Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gendl
gendl
Commits
42a8c2ab
Commit
42a8c2ab
authored
Jan 10, 2016
by
Dave Cooper
Browse files
added some debug statements. Issue with respondent in skeletonuielement. Added graph application
parent
d21b35bf
Changes
4
Hide whitespace changes
Inline
Sidebyside
apps/graphs/source/assembly.lisp
0 → 100644
View file @
42a8c2ab
(
inpackage
:graphplot
)
(
defineobject
assembly
(
baseobject
)
:inputslots
((
gridincrement
1
)
(
function
#'
identity
)
(
rangemin
5
)
(
rangemax
5
)
(
increment
0.1
)
(
showaxes?
t
)
(
showgrid?
(
the
showaxes?
))
(
domainmin
(
apply
#'
min
(
the
ysamples
)))
(
domainmax
(
apply
#'
max
(
the
ysamples
))))
:computedslots
((
rangeinterval
(

(
the
rangemax
)
(
the
rangemin
)))
(
domaininterval
(

(
the
domainmax
)
(
the
domainmin
)))
(
xsamples
(
listofnumbers
(
the
rangemin
)
(
the
rangemax
)
(
the
increment
)))
(
ysamples
(
mapcar
#'
(
lambda
(
x
)
(
funcall
(
the
function
)
x
))
(
the
xsamples
)))
(
curvesamplepoints
(
mapcar
#'
(
lambda
(
x
y
)
(
makepoint
x
y
0
))
(
the
xsamples
)
(
the
ysamples
))))
:objects
(
(
pointsdisplay
:type
'pointsdisplay
:hidden?
t
:points
(
the
curvesamplepoints
))
(
curve
:type
'fittedcurve
:points
(
the
curvesamplepoints
))
(
xaxis
:type
(
if
(
the
showaxes?
)
'line
'nullobject
)
:start
(
makepoint
(
the
rangemin
)
0
0
)
:end
(
makepoint
(
the
rangemax
)
0
0
)
:displaycontrols
(
list
:color
:green
:linestyle
:dashed
))
(
xgrid
:type
(
if
(
the
showgrid?
)
'line
'nullobject
)
:sequence
(
:size
(
floor
(
/
(
the
domaininterval
)
(
the
gridincrement
))))
:displaycontrols
(
list
:linethickness
0.5
:color
:grey
)
:start
(
makepoint
(
1+
(
the
rangemin
))
(
+
(
*
(
thechild
index
)
(
the
gridincrement
))
(
floor
(
the
domainmin
))
(
if
(
evenp
(
floor
(
the
domainmin
)))
0
1
))
0
)
:end
(
makepoint
(
1+
(
the
rangemax
))
(
+
(
*
(
thechild
index
)
(
the
gridincrement
))
(
floor
(
the
domainmin
))
(
if
(
evenp
(
floor
(
the
domainmin
)))
0
1
))
0
))
(
yaxis
:type
(
if
(
the
showaxes?
)
'line
'nullobject
)
:start
(
makepoint
0
(
the
domainmin
)
0
)
:end
(
makepoint
0
(
the
domainmax
)
0
)
:displaycontrols
(
list
:color
:red
:linestyle
:dashed
))
(
ygrid
:type
(
if
(
the
showgrid?
)
'line
'nullobject
)
:sequence
(
:size
(
floor
(
/
(
the
rangeinterval
)
(
the
gridincrement
))))
:displaycontrols
(
list
:linethickness
0.5
:color
:grey
)
:start
(
makepoint
(
+
(
*
(
thechild
index
)
(
the
gridincrement
))
(
floor
(
the
rangemin
))
1
)
(
1
(
the
domainmin
))
0
)
:end
(
makepoint
(
+
(
*
(
thechild
index
)
(
the
gridincrement
))
(
floor
(
the
rangemin
))
1
)
(
1
(
the
domainmax
))
0
))
))
apps/graphs/source/package.lisp
0 → 100644
View file @
42a8c2ab
(
gwl:definepackage
:graphplot
(
:export
#:ui
#:assembly
))
apps/graphs/source/ui.lisp
0 → 100644
View file @
42a8c2ab
(
inpackage
:graphplot
)
(
setq
*developing?*
t
)
(
defineobject
ui
(
baseajaxsheet
)
:computedslots
((
useraphael?
t
)
(
usex3dom?
t
)
(
functionspecs
(
list
(
list
:functionbody
(
the
(
functionbodies
0
)
value
)
:domainmin
5
:domainmax
5
)))
(
numberoffunctions
1
)
#+
nil
(
htmlsections
(
list
(
the
inputssection
)
(
the
resultssection
)
(
the
viewport
)))
(
mainsheetbody
(
withclwhostring
()
(
:p
(
when
*developing?*
(
str
(
the
developmentlinks
))))
(
:p
(
str
(
the
inputssection
maindiv
)))
(
:p
(
str
(
the
resultssection
maindiv
)))
(
:p
(
str
(
the
viewport
maindiv
)))))
(
rangemin
(
apply
#'
min
(
mapsend
(
the
graphs
)
:rangemin
)))
(
rangemax
(
apply
#'
max
(
mapsend
(
the
graphs
)
:rangemax
)))
(
domainmin
(
apply
#'
min
(
mapsend
(
the
graphs
)
:domainmin
)))
(
domainmax
(
apply
#'
max
(
mapsend
(
the
graphs
)
:domainmax
)))
)
:hiddenobjects
((
graphs
:type
'assembly
:sequence
(
:size
(
length
(
the
functionspecs
)))
:pseudoinputs
(
specs
)
:specs
(
nth
(
thechild
index
)
(
the
functionspecs
))
:function
(
let
((
form
(
getf
(
thechild
specs
)
:functionbody
)))
`
(
lambda
(
gdluser::x
)
,
(
let
((
*package*
(
findpackage
:graphplot
)))
form
)))
:parameters
(
removeplistkey
(
thechild
specs
)
:functionbody
))
(
functionbodies
:type
'textformcontrol
:sequence
(
:size
(
the
numberoffunctions
))
:ajaxsubmitonchange?
t
:domain
:passthru
:default
'
(
*
gdluser::x
2
)))
:objects
((
inputssection
:type
'sheetsection
:innerhtml
(
withclwhostring
()
(
dolist
(
function
(
listelements
(
the
functionbodies
)))
(
htm
(
str
(
theobject
function
htmlstring
))
:br
))))
(
resultssection
:type
'sheetsection
:innerhtml
(
withclwhostring
()
(
fmt
"~s"
(
the
(
graphs
0
)
function
))))
(
box
:type
'box
:width
(
twice
(
apply
#'
max
(
mapcar
#'
abs
(
list
(
the
rangemin
)
(
the
rangemax
)))))
:length
(
twice
(
apply
#'
max
(
mapcar
#'
abs
(
list
(
the
domainmin
)
(
the
domainmax
))))))
(
viewport
:type
'baseajaxgraphicssheet
:respondent
self
:viewdirectiondefault
:top
:imageformatdefault
:raphael
:displaylistobjectroots
(
listelements
(
the
graphs
))
:displaylistobjects
(
unless
(
eql
(
thechild
imageformat
)
:x3dom
)
(
list
(
the
box
)))
:length
500
:width
500
)))
gwl/ajax/source/skeletonuielement.lisp
View file @
42a8c2ab
...
...
@@ 269,9 +269,8 @@ formcontrols (default of these is also nil) will be respected. Default is nil."
(
registerhtmlsection!
(
section
)
#+
nil
(
when
*debug?*
(
progn
(
format
*traceoutput*
"~&Before:~%"
)
(
printvariables
self
)
(
printmessages
%htmlsectionrootpaths%
))
...
...
@@ 282,9 +281,8 @@ formcontrols (default of these is also nil) will be respected. Default is nil."
:test
#'
equalp
)
;;:remember? nil
:warnonnontoplevel?
nil
)))
#+
nil
(
when
*debug?*
(
when
t
(
format
*traceoutput*
"~&After:~%"
)
(
printmessages
%htmlsectionrootpaths%
)))
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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