Author: junrue Date: Mon Mar 13 00:40:49 2006 New Revision: 37
Added: trunk/docs/manual/ trunk/docs/manual/Makefile trunk/docs/manual/graphic-forms-reference.texinfo trunk/docs/manual/style.css Modified: trunk/src/tests/uitoolkit/layout-unit-tests.lisp trunk/src/uitoolkit/widgets/flow-layout.lisp Log: stub out reference manual
Added: trunk/docs/manual/Makefile ============================================================================== --- (empty file) +++ trunk/docs/manual/Makefile Mon Mar 13 00:40:49 2006 @@ -0,0 +1,47 @@ +# -*- Mode: Makefile; tab-width: 3; indent-tabs-mode: t -*- +# +# Makefile +# +# Copyright (c) 2006, Jack D. Unrue +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# 3. Neither the names of the authors nor the names of its contributors +# may be used to endorse or promote products derived from this software +# without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS "AS IS" AND ANY +# EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DIS- +# CLAIMED. IN NO EVENT SHALL THE AUTHORS AND CONTRIBUTORS BE LIABLE FOR ANY +# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +# + +# +# TODO: upgrade MSYS version of makeinfo so "--css-include=style.css" works +# +docs: + makeinfo --html graphic-forms-reference.texinfo + +clean: + find . ( -name "*.info" -o -name "*.aux" -o -name "*.cp" -o -name "*.fn" -o -name "*.fns" -o -name "*.ky" -o -name "*.log" -o -name "*.pg" -o -name "*.toc" -o -name "*.tp" -o -name "*.vr" -o -name "*.dvi" -o -name "*.cps" -o -name "*.vrs" ) -exec rm {} ; + rm -rf graphic-forms-reference + +# +# TODO: implement an upload target +#
Added: trunk/docs/manual/graphic-forms-reference.texinfo ============================================================================== --- (empty file) +++ trunk/docs/manual/graphic-forms-reference.texinfo Mon Mar 13 00:40:49 2006 @@ -0,0 +1,155 @@ +\input texinfo @c -*- Mode: Texinfo; Mode: auto-fill -*- +@c %**start of header +@setfilename graphic-forms-reference.info +@settitle Graphic-Forms Programming Reference +@exampleindent 2 + +@c @documentencoding utf-8 + +@c ============================= Macros ============================= + +@macro Function {args} +@defun \args\ +@end defun +@end macro + +@macro Macro {args} +@defmac \args\ +@end defmac +@end macro + +@macro Accessor {args} +@deffn {Accessor} \args\ +@end deffn +@end macro + +@macro GenericFunction {args} +@deffn {Generic Function} \args\ +@end deffn +@end macro + +@macro Variable {args} +@defvr {Special Variable} \args\ +@end defvr +@end macro + +@macro Condition {args} +@deftp {Condition Type} \args\ +@end deftp +@end macro + +@macro GFI +@acronym{GFW} +@end macro + +@macro GFG +@acronym{GFW} +@end macro + +@macro GFS +@acronym{GFW} +@end macro + +@macro GFW +@acronym{GFW} +@end macro + +@macro impnote {text} +@quotation +@strong{Implementor's note:} @emph{\text} +@end quotation +@end macro + +@c Info "requires" that x-refs end in a period or comma, or ) in the +@c case of @pxref. So the following implements that requirement for +@c the "See also" subheadings that permeate this manual, but only in +@c Info mode. +@ifinfo +@macro seealso {name} +@ref{\name}. +@end macro +@end ifinfo + +@ifnotinfo +@alias seealso = ref +@end ifnotinfo + +@c ==========================End Macros ============================= + +@c Show types, functions, and concepts in the same index. +@syncodeindex tp cp +@syncodeindex fn cp + +@copying +Copyright @copyright{} 2006, Jack D. Unrue <jdunrue at gmail.com> @* + +@quotation +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + 3. Neither the names of the authors nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + +@sc{THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS "AS IS" AND ANY +EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DIS +DISCLAIMED. IN NO EVENT SHALL THE AUTHORS AND CONTRIBUTORS BE LIABLE FOR ANY +DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.} +@end quotation +@end copying +@c %**end of header + +@titlepage +@title Graphic-Forms Programming Reference +@c @subtitle Version 0.2.0 +@c @author Jack D. Unrue + +@page +@vskip 0pt plus 1filll +@insertcopying +@end titlepage + +@contents + +@ifnottex +@node Top +@top Graphic-Forms Programming Reference +@insertcopying +@end ifnottex + +@menu +* Introduction:: +* Known Issues:: +@end menu + +@c =================================================================== +@c CHAPTER: Introduction + +@node Introduction +@chapter Introduction + +This will be introductory discussion of the Graphic-Forms library. + +@c =================================================================== +@c CHAPTER: Known Issues + +@node Known Issues +@chapter Known Issues + +This will be a list of known issues in the library. + +@bye
Added: trunk/docs/manual/style.css ============================================================================== --- (empty file) +++ trunk/docs/manual/style.css Mon Mar 13 00:40:49 2006 @@ -0,0 +1,48 @@ +body {font-family: century schoolbook, serif; + line-height: 1.3; + padding-left: 5em; padding-right: 1em; + padding-bottom: 1em; max-width: 60em;} +table {border-collapse: collapse} +span.roman { font-family: century schoolbook, serif; font-weight: normal; } +h1, h2, h3, h4, h5, h6 {font-family: Helvetica, sans-serif} +/*h4 {padding-top: 0.75em;}*/ +dfn {font-family: inherit; font-variant: italic; font-weight: bolder } +kbd {font-family: monospace; text-decoration: underline} +/*var {font-family: Helvetica, sans-serif; font-variant: slanted}*/ +var {font-variant: slanted;} +td {padding-right: 1em; padding-left: 1em} +sub {font-size: smaller} +.node {padding: 0; margin: 0} + +.lisp { font-family: monospace; + background-color: #F4F4F4; border: 1px solid #AAA; + padding-top: 0.5em; padding-bottom: 0.5em; } + +/* coloring */ + +.lisp-bg { background-color: #F4F4F4 ; color: black; } +.lisp-bg:hover { background-color: #F4F4F4 ; color: black; } + +.symbol { font-weight: bold; color: #770055; background-color : transparent; border: 0px; margin: 0px;} +a.symbol:link { font-weight: bold; color : #229955; background-color : transparent; text-decoration: none; border: 0px; margin: 0px; } +a.symbol:active { font-weight: bold; color : #229955; background-color : transparent; text-decoration: none; border: 0px; margin: 0px; } +a.symbol:visited { font-weight: bold; color : #229955; background-color : transparent; text-decoration: none; border: 0px; margin: 0px; } +a.symbol:hover { font-weight: bold; color : #229955; background-color : transparent; text-decoration: none; border: 0px; margin: 0px; } +.special { font-weight: bold; color: #FF5000; background-color: inherit; } +.keyword { font-weight: bold; color: #770000; background-color: inherit; } +.comment { font-weight: normal; color: #007777; background-color: inherit; } +.string { font-weight: bold; color: #777777; background-color: inherit; } +.character { font-weight: bold; color: #0055AA; background-color: inherit; } +.syntaxerror { font-weight: bold; color: #FF0000; background-color: inherit; } +span.paren1 { font-weight: bold; color: #777777; } +span.paren1:hover { color: #777777; background-color: #BAFFFF; } +span.paren2 { color: #777777; } +span.paren2:hover { color: #777777; background-color: #FFCACA; } +span.paren3 { color: #777777; } +span.paren3:hover { color: #777777; background-color: #FFFFBA; } +span.paren4 { color: #777777; } +span.paren4:hover { color: #777777; background-color: #CACAFF; } +span.paren5 { color: #777777; } +span.paren5:hover { color: #777777; background-color: #CAFFCA; } +span.paren6 { color: #777777; } +span.paren6:hover { color: #777777; background-color: #FFBAFF; }
Modified: trunk/src/tests/uitoolkit/layout-unit-tests.lisp ============================================================================== --- trunk/src/tests/uitoolkit/layout-unit-tests.lisp (original) +++ trunk/src/tests/uitoolkit/layout-unit-tests.lisp Mon Mar 13 00:40:49 2006 @@ -53,8 +53,9 @@ ;; container: visible ;; kids: uniform ;; - (let* ((size (gfw::flow-container-size '(:horizontal) t *flow-layout-kids1* -1 -1)) - (actual (gfw::flow-container-layout '(:horizontal) t *flow-layout-kids1* -1 -1)) + (let* ((layout (make-instance 'gfw:flow-layout :style '(:horizontal))) + (size (gfw::flow-container-size layout t *flow-layout-kids1* -1 -1)) + (actual (gfw::flow-container-layout layout t *flow-layout-kids1* -1 -1)) (expected-pnts nil)) (push (gfi:make-point :x 40 :y 0) expected-pnts) (push (gfi:make-point :x 20 :y 0) expected-pnts) @@ -70,8 +71,9 @@ ;; container: visible ;; kids: uniform ;; - (let* ((size (gfw::flow-container-size '(:vertical) t *flow-layout-kids1* -1 -1)) - (actual (gfw::flow-container-layout '(:vertical) t *flow-layout-kids1* -1 -1)) + (let* ((layout (make-instance 'gfw:flow-layout :style '(:vertical))) + (size (gfw::flow-container-size layout t *flow-layout-kids1* -1 -1)) + (actual (gfw::flow-container-layout layout t *flow-layout-kids1* -1 -1)) (expected-pnts nil)) (push (gfi:make-point :x 0 :y 20) expected-pnts) (push (gfi:make-point :x 0 :y 10) expected-pnts)
Modified: trunk/src/uitoolkit/widgets/flow-layout.lisp ============================================================================== --- trunk/src/uitoolkit/widgets/flow-layout.lisp (original) +++ trunk/src/uitoolkit/widgets/flow-layout.lisp Mon Mar 13 00:40:49 2006 @@ -37,10 +37,10 @@ ;;; helper functions ;;;
-(defun flow-container-size (style win-visible kids width-hint height-hint) +(defun flow-container-size (layout win-visible kids width-hint height-hint) (let ((max -1) (total 0) - (vert-orient (find :vertical style))) + (vert-orient (find :vertical (style-of layout)))) (loop for kid in kids do (let ((size (preferred-size kid (if vert-orient width-hint -1) @@ -59,11 +59,11 @@ (gfi:make-size :width max :height total) (gfi:make-size :width total :height max))))
-(defun flow-container-layout (style win-visible kids width-hint height-hint) +(defun flow-container-layout (layout win-visible kids width-hint height-hint) (let ((entries nil) (last-coord 0) (last-dim 0) - (vert-orient (find :vertical style))) + (vert-orient (find :vertical (style-of layout)))) (loop for kid in kids do (let ((size (preferred-size kid (if vert-orient width-hint -1) @@ -95,11 +95,11 @@
(defmethod compute-size ((layout flow-layout) (win window) width-hint height-hint) (with-children (win kids) - (flow-container-size (style-of layout) (visible-p win) kids width-hint height-hint))) + (flow-container-size layout (visible-p win) kids width-hint height-hint)))
(defmethod compute-layout ((layout flow-layout) (win window) width-hint height-hint) (with-children (win kids) - (flow-container-layout (style-of layout) (visible-p win) kids width-hint height-hint))) + (flow-container-layout layout (visible-p win) kids width-hint height-hint)))
(defmethod initialize-instance :after ((layout flow-layout) &key style) (unless (listp style)