diff --git a/collects/mysterx/scribblings/activex.scrbl b/collects/mysterx/scribblings/activex.scrbl deleted file mode 100644 index c2577903df..0000000000 --- a/collects/mysterx/scribblings/activex.scrbl +++ /dev/null @@ -1,16 +0,0 @@ -#lang scribble/doc -@(require "common.rkt") - -@title[#:tag "activex" #:style 'toc]{ActiveX and DHTML} - -A MysterX application consists of one or more browsers, which are -instances of the class @racket[mx-browser%]. - -@(deprecated) - -@local-table-of-contents[] - -@include-section["browsers.scrbl"] -@include-section["documents.scrbl"] -@include-section["html-events.scrbl"] -@include-section["html.scrbl"] diff --git a/collects/mysterx/scribblings/browsers.scrbl b/collects/mysterx/scribblings/browsers.scrbl deleted file mode 100644 index 7fe5881b93..0000000000 --- a/collects/mysterx/scribblings/browsers.scrbl +++ /dev/null @@ -1,130 +0,0 @@ -#lang scribble/doc -@(require "common.rkt") - -@title[#:tag "browsers"]{Browsers} - -@(deprecated) - -@defclass[mx-browser% object% ()]{ - -@defconstructor[([label string? "MysterX"] - [width (or/c exact-nonnegative-integer? (one-of/c 'default)) 'default] - [height (or/c exact-nonnegative-integer? (one-of/c 'default)) 'default] - [x (or/c exact-integer? (one-of/c 'default)) 'default] - [y (or/c exact-integer? (one-of/c 'default)) 'default] - [style-options - (listof (any-of/c 'iconize 'maximize 'no-system-menu - 'no-thick-border 'scrollbars))])]{ - - Creates an instance of a MysterX browser. The @racket[label] - argument is a string for the document caption, with default . The - @racket[width], @racket[height], @racket[x], and @racket[y] give the - size and placement of the browser window on the desktop, with - defaults provided by Windows. When @racket[style-options] includes - @racket['scrollbars], the vertical scrollbar is disabled if - scrolling is unnecessary, and the horizontal scrollbar disappears if - scrolling is unnecessary. - - Although the browser window cannot be hidden initially, it can be - iconized. The @method[mx-browser% restore] method can be used to - restore an iconized browser to an ordinary window.} - -@defmethod[(current-document) (is-a?/c mx-document<%>)]{ - - Returns the current document in the browser.} - -@defmethod[(print-document) void?]{ - - Prints the document displayed by the browser to the default - printer. As an unintentional side-effect, the browser - window is minimized.} - -@defmethod[(show [show? any/c]) void?]{ - - If @racket[show?] is @racket[#f], the browser window is hidden. - Otherwise, the window is shown.} - -@defmethod[(navigate [url string?]) string?]{ - - Navigates the browser to the URL given by @racket[url]. - Any DHTML changes to the page associated with the URL - are not shown. Returns a string that is the actual URL - navigated to.} - -@defmethod[(navigate/status [url string?]) - (list/c string? (or/c false/c integer? (one-of/c 'no-status)))]{ - - Navigates the browser to the URL given by @racket[url]. - Any DHTML changes to the page associated with the URL - are not shown. Returns a list, whose first element string that - is the actual URL navigated to, and whose second element is - a status code, one of: @racket[#f], indicating no status could be - obtained; a number, such as @racket[200] or @racket[404], indicating the - http status; or @racket['no-status], indicating that @racket[url] does not - denote a URL with the ``http'' scheme.} - -@defmethod[(go-back) string?]{ - - Navigates the browser back to a URL within its history list. - Any DHTML changes to the page associated with the URL - are not shown. Returns a string that is the actual URL - navigated to.} - -@defmethod[(go-forward) string?]{ - - Navigates the browser forward to a URL within its history list. - Any DHTML changes to the page associated with the URL are - not shown. Returns a string that is the actual URL - navigated to.} - -@defmethod[(refresh) boolean?]{ - - Refreshes the document in the browser. Returns @racket[#t] - if the refresh is successful, @racket[#f] otherwise.} - -@defmethod[(iconize) void?]{ - - Iconizes the browser window.} - -@defmethod[(restore) void?]{ - - Restores the browser window, if it has been iconized.} - -@defmethod[(current-url) string?]{ - - Returns a string indicating the currently displayed URL. } - -@defmethod[(register-event-handler [elem (is-a?/c mx-element%)] - [f ((is-a?/c mx-event<%>) . -> . any)]) - void?]{ - - Registers an event handler for the HTML element @racket[elem]. - The result of @racket[f] is discarded.} - -@defmethod[(unregister-event-handler [elem (is-a?/c mx-element%)]) void?]{ - - Unregisters an event handler for an HTML element - in the browser.} - -@defmethod[(handle-events) void?]{ - - Creates a thread to handle events using the registered event - handlers.} - -@defmethod[(stop-handling-events) void?]{ - - Kills the thread currently handling events for - the browser.} - -} - -@; ---------------------------------------- - -@defproc[(block-while-browsers) void?]{ - - Blocks until all browser windows have been closed or hidden, using - the show method of @racket[mx-browser%]. This is useful when a - MysterX program file is run as a script, to prevent @exec{mzscheme} - or @exec{mred} from closing prematurely.} - - diff --git a/collects/mysterx/scribblings/documents.scrbl b/collects/mysterx/scribblings/documents.scrbl deleted file mode 100644 index 7098b9aa58..0000000000 --- a/collects/mysterx/scribblings/documents.scrbl +++ /dev/null @@ -1,117 +0,0 @@ -#lang scribble/doc -@(require "common.rkt") - -@title[#:tag "documents"]{Documents} - -@(deprecated) - - A browser contains one document at a time. If - hyperlinks are clicked, or the navigation methods - (navigate, go-forward, go-back) are used, the - document changes. - -@definterface[mx-document<%> ()]{ - -@defmethod[(insert-html [html string?]) void?]{ - - Inserts the specified HTML string at the - beginning of the document.} - -@defmethod[(append-html [html string?]) void?]{ - - Appends the specified HTML string at the end of - the document.} - -@defmethod[(replace-html [html string?]) void?]{ - - Replace the current HTML in the document with - the specified HTML string.} - -@defmethod[(objects) (listof com-object?)]{ - - Returns a list of COM objects, including ActiveX - controls, that occur in the document. The order - of the objects is the same as in the document.} - -@defmethod[(insert-object-from-coclass [coclass string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - com-object?]{ - - Inserts a COM object with class @racket[coclass] at the beginning of - the document. The optional @racket[size] argument gives an - interpretation for the width and height, where @racket['percent] - indicates that the width and height are a fixed percentage of the - document window size.} - -@defmethod[(insert-object-from-progid [progid string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - com-object?]{ - - Like @method[mx-document<%> insert-object-from-coclass], but with a - ProgID instead of a COM class.} - -@defmethod[(append-object-from-coclass [coclass string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - com-object?]{ - - Like @method[mx-document<%> insert-object-from-coclass], but adds to the - end of the document.} - - -@defmethod[(append-object-from-progid [progid string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - com-object?]{ - - Like @method[mx-document<%> insert-object-from-progid], but adds to the - end of the document.} - -@defmethod[(title) string?]{ - - Returns a string indicating the document's title, that is, - the text that appears within HTML TITLE tags. If the document - has no title, the empty string is returned.} - -@defmethod[(find-element [tag string?] - [id string?] - [index exact-nonnegative-integer? 0]) - (is-a?/c mx-element%)]{ - - Returns an object that encapsulates an HTML element, where - @racket[tag] names an HTML tag, and @racket[id] names the @racket["id"] - attribute of the HTML element. The @racket[index] is a nonnegative - integer indicating the zero-based index of the element among all - elements with the same @racket[tag] and @racket[id]. The ordering - of elements is defined by Internet Explorer. The requested element - must be within the document's @racket["body"] tags or the - @racket["body"] element itself.} - -@defmethod[(find-element-by-id-or-name - [id string?] - [index exact-nonnegative-integer? 0]) - (is-a?/c mx-element%)]{ - - Returns an object that encapsulates an HTML element, where - @racket[id] names either the @racket["id"] or @racket["name"] - attribute of the HTML element. The @racket[index] is a nonnegative - integer indicating the zero-based index of the element among all - elements with the same @racket["id"] or @racket["name"]. The ordering - of elements is defined by Internet Explorer. The requested element - must be within the document's @racket["body"] tags or the - @racket["body"] element itself.} - -@defmethod[(elements-with-tag [tag string?]) - (listof (is-a?/c mx-element%))]{ - - Returns a list of elements with the HTML tag given by @racket[tag]. - The requested elements must be within the document's @racket["body"] - tags or the @racket["body"] element itself.} - -} diff --git a/collects/mysterx/scribblings/html-element.scrbl b/collects/mysterx/scribblings/html-element.scrbl deleted file mode 100644 index 26ff8d910e..0000000000 --- a/collects/mysterx/scribblings/html-element.scrbl +++ /dev/null @@ -1,573 +0,0 @@ -#lang scribble/doc -@(require "common.rkt" scribble/bnf scribble/decode scribble/struct - (for-syntax scheme/base)) - -@(define-syntax-rule (filter-table (name (option0 contract0) - (option contract) ...) ...) - (let ([spacer (hspace 1)] - [to-flow (lambda (e) - (make-flow (list (make-paragraph (list e)))))]) - (make-table - #f - (append - (list (list (to-flow spacer) - (to-flow @emph{filter}) - (to-flow spacer) - (to-flow @emph{option}) - (to-flow spacer) - (to-flow @emph{value}))) - (list - (list (to-flow spacer) - (to-flow (racket 'name)) - (to-flow spacer) - (to-flow (racket 'option0)) - (to-flow spacer) - (make-flow (list (racketblock0 contract0)))) - (list (to-flow spacer) - (to-flow spacer) - (to-flow spacer) - (to-flow (racket 'option)) - (to-flow spacer) - (make-flow (list (racketblock0 contract)))) - ...) - ...)))) - -@(define-syntax-rule (argmatch id) - @elem{The argument must be a possible result from @method[mx-element% id].}) - -@(define-syntax-rule (resultmatch id) - @elem{Possible results are the same as for @method[mx-element% id].}) - -@(define-syntax-rule (valmatch id) - @elem{The non-string repersentation is the same as for @method[mx-element% id].}) - -@(define-syntax (defmethods stx) - (syntax-case stx () - [(_ id contract . more) - (with-syntax ([id-native - (datum->syntax #'id - (string->symbol - (format "~s-native" (syntax-e #'id))))] - [set-id! - (datum->syntax #'id - (string->symbol - (format "set-~s!" (syntax-e #'id))))] - [set-id-native! - (datum->syntax #'id - (string->symbol - (format "set-~s-native!" (syntax-e #'id))))] - [css-string (format "~a" (syntax-e #'id))]) - #'(make-splice - (list - @defmethod*[([(id) contract] - [(id-native) string?] - [(set-id! [v contract]) void?] - [(set-id-native! [str string?]) void?])]{ - Retrieves or sets a value describing the CSS @tt[css-string] for - the element. - - @(make-splice (list . more))})))])) - -@(define-syntax-rule (defdef defXmethods ret-contract arg-contract) - (define-syntax (defXmethods stx) - (syntax-case stx () - [(_ id) - (with-syntax ([set-id! - (datum->syntax #'id - (string->symbol - (format "set-~s!" (syntax-e #'id))))] - [css-string (format "~a" (syntax-e #'id))]) - #'@defmethod*[([(id) ret-contract] - [(set-id! [v arg-contract]) void?])]{ - Retrieves or sets the CSS @tt[css-string] for the element.})]))) - -@(defdef defboolmethods boolean? any/c) -@(defdef defintmethods exact-integer? exact-integer?) -@(defdef defrealmethods real? real?) - -@; ---------------------------------------------------------------------- - -@title[#:tag "html-element"]{HTML Elements} - -@(deprecated) - -@defclass[mx-element% object% ()]{ - -@defmethod[(get-html) - string?]{ - - Returns a string containing all the HTML between the pair of - tags represented by the element.} - -@defmethod[(get-text) - string?]{ - - Returns a string containing just the text between the pair of - tags represented by the element. Any nested HTML tags - are not contained in the returned string.} - -@defmethod[(insert-html [html string?]) - void?]{ - - Places the HTML given by the string @racket[html] before the element.} - -@defmethod[(append-html [html string?]) - void?]{ - - Places the HTML given by the string @racket[html] after the element.} - -@defmethod[(replace-html [html string?]) - void?]{ - - Replaces the HTML in the element with the string @racket[html]. You - must use the @method[mx-document<%> find-element] or - @method[mx-document<%> find-element-by-id-or-name] methods of - @racket[mx-document<%>] to retrieve the updated element.} - -@defmethod[(insert-text [txt string?]) - void?]{ - - Places the text given by the string @racket[txt] before the HTML element.} - -@defmethod[(append-text [txt string?]) - void?]{ - - Places the text given by the string @racket[txt] after the HTML element.} - -@defmethod[(insert-object-from-coclass [coclass string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - void?]{ - - Composes @racket[coclass->html] with @method[mx-element% insert-html].} - -@defmethod[(insert-object-from-progid [coclass string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - void?]{ - - Composes @racket[progid->html] with @method[mx-element% insert-html].} - -@defmethod[(append-object-from-coclass [coclass string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - void?]{ - - Composes @racket[coclass->html] with @method[mx-element% append-html].} - -@defmethod[(append-object-from-progid [coclass string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - void?]{ - - Composes @racket[progid->html] with @method[mx-element% append-html].} - -@defmethod[(focus) - void?]{ - - Sets the focus to the element. This method works only with - Internet Explorer 5 and later.} - -@defmethod[(selection) - string?]{ - - If the element has the @racket["select"] tag, returns a string - indicating the value of the current selection. Otherwise, an - exception s raised. The value of the selection may be different - from the string visible in the dropdown list.} - -@defmethod[(set-selection! [val string?]) - void?]{ - - If the element has the @racket["select"] tag, sets the selection to - the entry with the value @racket[val], a string. Otherwise, an - exception is raised. The value of the selection may be different - from the string visible in the dropdown list.} - -@defmethod[(attribute [attr string?]) - (or/c string? real? boolean?)]{ - - Retrieves the attribute named by the string @racket[attr]. The return - value has a type that depends on the attribute.} - -@defmethod[(set-attribute! [attr string?] - [val (or/c string? real? boolean?)]) - void?]{ - - Sets the attribute named by the string @racket[attr]. The new - value @racket[val] has a type that depends on the attribute.} - -@defmethod[(click) - void?]{ - - Simulates a mouse click on the element. } - -@defmethod[(tag) - string?]{ - - Retrieves the element's HTML tag.} - -@defmethods[font-family - (listof string?)] - -@defmethods[font-style - (one-of/c 'normal 'italic 'oblique)] - -@defmethods[font-variant - (one-of/c 'normal 'small-caps)] -@defmethods[font-weight - (one-of/c 'normal 'bold 'bolder 'lighter - 100 200 300 400 500 600 700 800 900)] - -@defmethod*[([(font-native) string?] - [(set-size-native! [fs string?]) void?])]{ - - Retrieves or sets a string that encodes the CSS @tt{font-style}, - @tt{font-variant}, @tt{font-weight}, @tt{font-size}, - @tt{line-height}, and @tt{font-family} using the format - - @BNF-seq[@optional[@BNF-alt/close[@nonterm{font-style} @nonterm{font-variant} @nonterm{font-weight}]] - @nonterm{font-size} - @optional[@nonterm{line-height}] - @nonterm{font-family}]} - -@defmethods[font-size - (or/c - (one-of/c - 'xx-small 'x-small 'small 'medium 'large 'x-large 'xx-large - 'larger 'smaller) - css-length? - css-percentage?)] - -@defmethod*[([(background-native) string?] - [(set-background-native! [b string]) void?])]{ - - Gets or sets the element's CSS @tt{background-color}, @tt{background-image}, - @tt{background-repeat}, @tt{background-attachment}, and @tt{background-position} - using the string @racket[b].} - - -@defmethods[background-image - (or/c (one-of/c 'none) string?)] - -@defmethods[background-repeat - (one-of/c 'no-repeat 'repeat 'repeat-x 'repeat-y)] - -@defmethods[background-position - (or/c - css-length? - css-percentage? - (one-of/c 'left 'center 'right) - (list/c - (or/c css-length? css-percentage? - (one-of/c 'left 'center 'right)) - (or/c css-length? css-percentage? - (one-of/c 'left 'center 'right))))] - -@defmethods[text-decoration - (listof (one-of/c 'none 'underline 'overline 'line-through 'blink))] - -@defmethods[text-transform - (one-of/c 'none 'capitalize 'uppercase 'lowercase)] - -@defmethods[text-align - (one-of/c 'left 'right 'center 'justify)] -@defmethods[margin - (listof (or/c (one-of 'auto) - css-length? - css-percentage?))]{ - - A list representation contains one to four elements. A single - element applies to all sides; two elements are top--bottom and - left--right, respectively; four elements are top, left, bottom, and - right, respectively.} - - -@defmethods[padding - (listof (or/c css-length? css-percentage?))]{ - - The list contains one to four elements, which apply to sides as for - @method[mx-element% margin].} - -@defmethods[border - (listof (or/c (or/c (one-of/c 'medium 'thin 'thick) css-length?) - (one-of/c 'none 'dotted 'dashed 'solid 'double - 'groove 'ridge 'inset 'outset) - (or/c symbol? string?)))]{ - - Each element of the list describes a width, style, or color. A color - is a symbol indicating a color or an RGB string.} - -@defmethods[border-top ....]{@valmatch[border]} -@defmethods[border-bottom ....]{@valmatch[border]} -@defmethods[border-left ....]{@valmatch[border]} -@defmethods[border-right ....]{@valmatch[border]} - -@defmethods[border-color (listof (or/c symbol? string?))]{ - - The list contains one to four elements, with side assignments - as for @method[mx-element% margin].} - -@defmethods[border-width - (listof (or/c css-length? - (one-of/c 'medium 'thin 'thick)))]{ - - The list contains one to four elements, with side assignments - as for @method[mx-element% margin].} - -@defmethods[border-style - (one-of/c 'none 'dotted 'dashed 'solid 'double - 'groove 'ridge 'inset 'outset)] - -@defmethods[border-top-style ....]{@valmatch[border-style]} -@defmethods[border-bottom-style ....]{@valmatch[border-style]} -@defmethods[border-left-style ....]{@valmatch[border-style]} -@defmethods[border-right-style ....]{@valmatch[border-style]} - -@defmethods[style-float - (one-of/c 'none 'left 'right)] - -@defmethods[clear - (one-of/c 'none 'left 'right 'both)] - -@defmethods[display - (one-of/c 'block 'none 'inline 'list-item - 'table-header-group 'table-footer-group)] - -@defmethods[visibility - (one-of/c 'inherit 'visible 'hidden)] - -@defmethods[list-style-type - (one-of/c 'disc 'circle 'square 'decimal - 'lower-roman 'upper-roman - 'lower-alpha 'upper-alpha 'none)] - -@defmethods[list-style-position - (one-of/c 'outside 'inside)] - -@defmethods[list-style-image (lambda (s) - (and string? - (regexp-match? #rx"^(none|url[(].*[)])$" s)))] - -@defmethods[list-style list?]{ - - A list representation contains one to three elements, - which have the same representations as for - @method[mx-element% list-style-type], - @method[mx-element% list-style-position], - and @method[mx-element% list-style-image]. The - values may appear in any order.} - -@defmethods[position - (one-of/c 'absolute 'relative 'static)] - -@defmethods[overflow - (one-of/c 'visible 'scroll 'hidden 'auto)] - -@defmethods[pagebreak-before - (one-of/c 'always 'auto 'none)] -@defmethods[pagebreak-after - (one-of/c 'always 'auto 'none)] - -@defmethod*[([(css-text-native) string?] - [(set-css-text-native! [txt string?]) void?])]{ - - Retrieves or sets a string describing the CSS @tt{text} for - the element.} - -@defmethods[cursor - (one-of/c 'auto 'crosshair 'default - 'hand 'move 'n-resize 'ne-resize 'nw-resize 's-resize - 'se-resize 'sw-resize 'e-resize 'w-resize 'text 'wait - 'help)] - -@defmethods[clip - (or/c (one-of/c 'auto) - (list/c (or/c (one-of/c 'auto) - css-length?) - (or/c (one-of/c 'auto) - css-length?) - (or/c (one-of/c 'auto) - css-length?) - (or/c (one-of/c 'auto) - css-length?)))] - -@defmethods[filter - (cons/c symbol? (listof (list/c symbol? any/c)))]{ - - For a filter value that combines a symbol with a list, the symbol is - a filter name, and the list maps symbol option names to values. The - table below shows the possible options and value types for each - possible filter name. - -@filter-table[ -( alpha (enabled boolean?) - (finish-opacity (integer-in 0 100)) - (opacity (integer-in 0 100)) - (start-x exact-integer?) - (start-y exact-integer?) - (finish-x exact-integer?) - (finish-y exact-integer?) - (style (one-of/c 'uniform - 'linear - 'radial - 'rectangular))) -( blend-trans (enable boolean?) - (duration real?) - (status (one-of/c 'stopped - 'applied - 'playing))) -( blur (add boolean?) - (enabled boolean?) - (direction (one-of/c 0 45 90 - 135 180 - 225 270 - 315)) - (strength (integer-in 1 100))) -( chroma (enabled boolean?) - (color string?)) -( drop-shadow (enabled boolean?) - (off-x exact-integer?) - (off-y exact-integer?)) -( flip-horizontal (enabled boolean?)) -( flip-vertical (enabled boolean?)) -( glow (enabled boolean?) - (color string?) - (strength (integer-in 1 100))) -( gray (enabled boolean?)) -( invert (enabled boolean?)) -( light (enabled boolean?)) -( mask (enabled boolean?) - (color string?)) -( redirect (enabled boolean?)) -( reveal-trans (enabled boolean?) - (duration real?) - (status (one-of/c 'stopped - 'applied - 'playing))) -( shadow (enabled boolean?) - (color string?) - (direction (one-of/c 0 45 90 - 135 180 - 225 270 - 315))) -( wave (enabled boolean?) - (freq (and/c real? - (not/c negative?))) - (light-strength (integer-in 1 100))) -( x-ray (enabled boolean?)) -]} - -@defmethod[(style-string) - string?]{ - - Retrieves a string describing the complete CSS - description for the element.} - -@defboolmethods[text-decoration-none] -@defboolmethods[text-decoration-underline] -@defboolmethods[text-decoration-overline] -@defboolmethods[text-decoration-linethrough] -@defboolmethods[text-decoration-blink] - -@defintmethods[pixel-top] -@defintmethods[pixel-left] -@defintmethods[pixel-width] -@defintmethods[pixel-height] - -@defrealmethods[pos-top] -@defrealmethods[pos-left] -@defrealmethods[pos-width] -@defrealmethods[pos-height] - -@defmethods[color - (or/c symbol? string?)] -@defmethods[background-color - (or/c symbol? string?)] - -@defmethods[background-position-x - (or/c css-length? css-percentage? - (one-of/c 'left 'center 'right))] -@defmethods[background-position-y - (or/c css-length? css-percentage? - (one-of/c 'left 'center 'right))] - -@defmethods[letter-spacing - (or/c css-length? (one-of/c 'normal))] - -@defmethods[vertical-align - (one-of/c 'baseline 'sub 'super 'top 'middle - 'bottom 'text-top 'text-bottom)] -@defmethods[text-indent - (or/c css-length? css-percentage?)] - -@defmethods[line-height - (or/c css-length? css-percentage? - (one-of/c 'normal))] - -@defmethods[margin-top - (or/c css-length? css-percentage? - (one-of/c 'auto))] -@defmethods[margin-bottom - (or/c css-length? css-percentage? - (one-of/c 'auto))] -@defmethods[margin-left - (or/c css-length? css-percentage? - (one-of/c 'auto))] -@defmethods[margin-right - (or/c css-length? css-percentage? - (one-of/c 'auto))] - -@defmethods[padding-top - (or/c css-length? css-percentage?)] -@defmethods[padding-bottom - (or/c css-length? css-percentage?)] -@defmethods[padding-left - (or/c css-length? css-percentage?)] -@defmethods[padding-right - (or/c css-length? css-percentage?)] - -@defmethods[border-top-color - (or/c symbol? string?)] -@defmethods[border-bottom-color - (or/c symbol? string?)] -@defmethods[border-left-color - (or/c symbol? string?)] -@defmethods[border-right-color - (or/c symbol? string?)] - -@defmethods[border-top-width - (or/c css-length? - (one-of/c 'medium 'thin 'thick))] -@defmethods[border-bottom-width - (or/c css-length? - (one-of/c 'medium 'thin 'thick))] -@defmethods[border-left-width - (or/c css-length? - (one-of/c 'medium 'thin 'thick))] -@defmethods[border-right-width - (or/c css-length? - (one-of/c 'medium 'thin 'thick))] - -@defmethods[width - (or/c css-length? css-percentage? - (one-of/c 'auto))] -@defmethods[height - (or/c css-length? css-percentage? - (one-of/c 'auto))] - -@defmethods[top - (or/c css-length? css-percentage? - (one-of/c 'auto))] -@defmethods[left - (or/c css-length? css-percentage? - (one-of/c 'auto))] - -@defmethods[z-index - (or/c exact-integer? (one-of/c 'auto))] - -} diff --git a/collects/mysterx/scribblings/html-events.scrbl b/collects/mysterx/scribblings/html-events.scrbl deleted file mode 100644 index 80e11bd61b..0000000000 --- a/collects/mysterx/scribblings/html-events.scrbl +++ /dev/null @@ -1,100 +0,0 @@ -#lang scribble/doc -@(require "common.rkt") - -@title[#:tag "html-events"]{HTML Events} - -@(deprecated) - - MysterX HTML events are generated by mouse and - keyboard interaction with HTML elements in a - document. - -@definterface[mx-event<%> ()]{ - -@defmethod*[ -([(keypress?) boolean?] - [(keydown?) boolean?] - [(keyup?) boolean?] - [(mousedown?) boolean?] - [(mousemove?) boolean?] - [(mouseover?) boolean?] - [(mouseout?) boolean?] - [(mouseup?) boolean?] - [(click?) boolean?] - [(dblclick?) boolean?] - [(error?) boolean?])]{ - - Exactly one of these methods returns @racket[#t] to indicate the type - of a given event, and the others return @racket[#f] for the event.} - -@defmethod[(alt-key) boolean?]{ - - Returns @racket[#t] if the Alt key was pressed when the - event was generated, @racket[#f] otherwise.} - -@defmethod[(ctrl-key) boolean?]{ - - Returns @racket[#t] if the Ctrl key was pressed when the - event was generated, @racket[#f] otherwise. } - -@defmethod[(from-tag) string?]{ - - Returns a string indicating the tag of the HTML element where the - mouse is being moved from. The return value is valid only for - events for which @method[mx-event<%> mouseover?] or @method[mx-event<%> - mouseout?] produces @racket[#t].} - -@defmethod[(from-id) string?]{ - - Returns a string indicating the identifier of the HTML element where - the mouse is being moved from. Return value is valid only for - events for which @method[mx-event<%> mouseover?] or @method[mx-event<%> - mouseout?] produces @racket[#t].} - -@defmethod[(id) string?]{ - - Returns a string indicating the identifier of - the HTML element where the event occurred.} - -@defmethod[(keycode) exact-integer?]{ - - Returns a number indicating the keycode for the key that generated - the event. Return value is valid only for events for which - @method[mx-event<%> keypress?], @method[mx-event<%> keydown?], or - @method[mx-event<%> keyup?] produces @racket[#t].} - -@defmethod[(shift-key) boolean?]{ - - Returns @racket[#t] if the Shift key was pressed when the - event was generated, @racket[#f] otherwise.} - -@defmethod[(tag) string?]{ - - Returns a string indicating the HTML tag of the - element where the event occurred.} - -@defmethod[(to-tag) string?]{ - - Returns a string indicating the tag of the target HTML element where - the mouse is being moved to. Return value is valid only for events - for which @method[mx-event<%> mouseover?] or @method[mx-event<%> - mouseout?] produces @racket[#t].} - -@defmethod[(to-id) boolean?]{ - - Returns a string indicating the identifier of the target HTML - element where the mouse is being moved from. Return value is valid - only for events for which @method[mx-event<%> mouseover?] or - @method[mx-event<%> mouseout?] produces @racket[#t].} - -@defmethod[(x) exact-integer?]{ - - Returns an integer indicating the x-coordinate - within the document where the event occurred.} - -@defmethod[(y) exact-integer?]{ - - Returns an integer indicating the y-coordinate - within the document where the event occurred.} - -} diff --git a/collects/mysterx/scribblings/html.scrbl b/collects/mysterx/scribblings/html.scrbl deleted file mode 100644 index 694d674bc8..0000000000 --- a/collects/mysterx/scribblings/html.scrbl +++ /dev/null @@ -1,137 +0,0 @@ -#lang scribble/doc -@(require "common.rkt") - -@; ---------------------------------------------------------------------- - -@title[#:tag "html" #:style 'toc]{HTML and Dynamic HTML} - -@(deprecated) - - The @racket[mx-element%] class encapsulates HTML elements. By - calling the methods of the class, you can change the appearance of - elements, and place new HTML before or after the element. While the - methods are described here, a good DHTML reference, such as - Goodman's @italic{Dynamic HTML} will have more complete information. - - Many of the @racket[mx-element%] methods have two variants, a - version that takes or returns Racket data, and another - @racketidfont{-native} version that takes or returns a string. For - methods that return values of element properties, we assume two - characteristics, which we do not mention in the methods' - documentation: 1) Native methods return the empty string for - properties that have not been set, and 2) non-native methods raise - an error for properties that have not been set. - -@; ---------------------------------------- - -@include-section["html-element.scrbl"] - -@; ---------------------------------------- - -@section{Generating ActiveX HTML} - -@(deprecated) - -@deftogether[( -@defproc[(coclass->html [name string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - string?] -@defproc[(progid->html [name string?] - [width exact-integer?] - [height exact-integer?] - [size (one-of/c 'pixels 'percent) 'pixels]) - string?] -)]{ - - Returns a string containing HTML which when inserted into a document - loads the COM object with the COM class or ProgID given by - @racket[name]. This procedure is suitable for placing ActiveX - controls within complex HTML. The optional @racket[size] argument - gives an interpretation for the @racket[width] and @racket[height] - arguments; by default, @racket[size] is @racket['pixels], but may - also be @racket['percent], indicating that the width and height are - a fixed percentage of the document window size.} - -@; ---------------------------------------- - -@section{CSS} - -@(deprecated) - - In the @racket[mx-element%] method descriptions, ``CSS'' refers to - the Cascading Style Sheets specification. A CSS length is string - consisting of a decimal integer number followed by one of the units - @litchar{px} (pixels), @litchar{em} (font height), @litchar{ex} - (height of an ``x''), @litchar{in} (inches), @litchar{cm} - (centimeters), @litchar{mm} (millimeters), @litchar{pc} (picas), or - @litchar{pt} (points). A CSS percentage is a string consisting of a - decimal real number followed by @litchar{%}. When using - @racketidfont{-native} methods, CSS lengths and percentages are - given as strings. For use by non-native methods, the - @racket[css-percentage] and @racket[css-length] structures have been - defined. - -@deftogether[( -@defstruct[css-percentage ([num real?])] -@defstruct[css-length ([num real?][units (symbols em ex cm mm in pt pc px)])] -)] - -@; ---------------------------------------- - -@section{Colors} - -@(deprecated) - - Many element properties represent colors. In HTML, colors may be - represented by an RGB string, which contains 7 characters. The first - character is @litchar{#}, the rest are hexadecimal digits - (@litchar{0}-@litchar{9} and @litchar{a}-@litchar{f} or - @litchar{A}-@litchar{F}); the first two digits are for the red - component of the color, the middle two for the green component, and - the last two for the blue component. For example, @racket["#FFFFFF"] - is white, @racket["#000000"] is black, and @racket["#00FF00"] is - green. - - There are also predefined color names. The @racketidfont{-native} - methods use these names in strings, while their nonnative counterpart - methods use the names as symbols. - - The predefined color names are: - -@verbatim[#:indent 2]{ - aliceblue antiquewhite aqua aquamarine azure - beige bisque black blanchedalmond blue - blueviolet brown burlywood cadetblue chartreuse - chocolate coral cornflower cornsilk crimson cyan - darkblue darkcyan darkgoldenrod darkgray - darkgreen darkkhaki darkmagenta darkolivegreen - darkorange darkorchid darkred darksalmon - darkseagreen darkslateblue darkslategray - darkturquoise darkviolet deeppink deepskyblue - dimgray dodgerblue firebrick floralwhite - forestgreen fuchsia gainsboro ghostwhite gold - goldenrod gray green greenyellow honeydew - hotpink indianred indigo ivory khaki lavender - lavenderblush lawngreen lemonchiffon lightblue - lightcoral lightcyan lightgoldenrodyellow - lightgreen lightgray lightpink lightsalmon - lightseagreen lightskyblue lightslategray - lightsteelblue lightyellow lime limegreen linen - magenta maroon mediumaquamarine mediumblue - mediumorchid mediumpurple mediumseagreen - mediumslateblue mediumspringgreen - mediumturquoise mediumvioletred midnightblue - mintcream mistyrose moccasin navajowhite navy - oldlace olive olivedrab orange orangered orchid - palegoldenrod palegreen paleturquoise - palevioletred papayawhip peachpuff peru pink - plum powderblue purple red rosybrown royalblue - saddlebrown salmon sandybrown seagreen seashell - sienna silver skyblue slateblue slategray snow - springgreen steelblue tan teal thistle tomato - turquoise violet wheat white whitesmoke yellow - yellowgreen -} -