diff --git a/extra/constructors/authors.txt b/basis/constructors/authors.txt similarity index 100% rename from extra/constructors/authors.txt rename to basis/constructors/authors.txt diff --git a/extra/constructors/constructors-tests.factor b/basis/constructors/constructors-tests.factor similarity index 100% rename from extra/constructors/constructors-tests.factor rename to basis/constructors/constructors-tests.factor diff --git a/extra/constructors/constructors.factor b/basis/constructors/constructors.factor similarity index 100% rename from extra/constructors/constructors.factor rename to basis/constructors/constructors.factor diff --git a/basis/html/html-docs.factor b/basis/html/html-docs.factor new file mode 100644 index 0000000000..8c4b2934d0 --- /dev/null +++ b/basis/html/html-docs.factor @@ -0,0 +1,6 @@ +IN: html +USING: help.markup help.syntax strings ; + +HELP: simple-page +{ $values { "title" string } { "head" "XML data" } { "body" "XML data" } } +{ $description "Constructs a simple XHTML page with a " { $snippet "head" } " and " { $snippet "body" } " tag. The given XML data is spliced into the two child tags, and a title is also added to the head tag." } ; \ No newline at end of file diff --git a/basis/html/html.factor b/basis/html/html.factor index e86b4917d7..e446c66d8c 100644 --- a/basis/html/html.factor +++ b/basis/html/html.factor @@ -15,7 +15,7 @@ IN: html <-> - XML> ; inline + XML> ; : render-error ( message -- xml ) [XML <-> XML] ; diff --git a/extra/images/authors.txt b/basis/images/authors.txt similarity index 100% rename from extra/images/authors.txt rename to basis/images/authors.txt diff --git a/extra/images/backend/authors.txt b/basis/images/backend/authors.txt similarity index 100% rename from extra/images/backend/authors.txt rename to basis/images/backend/authors.txt diff --git a/extra/images/backend/backend.factor b/basis/images/backend/backend.factor similarity index 98% rename from extra/images/backend/backend.factor rename to basis/images/backend/backend.factor index 6d73a253ae..756b98efee 100644 --- a/extra/images/backend/backend.factor +++ b/basis/images/backend/backend.factor @@ -1,7 +1,7 @@ ! Copyright (C) 2009 Doug Coleman. ! See http://factorcode.org/license.txt for BSD license. USING: accessors kernel grouping fry sequences combinators -images.bitmap math ; +math ; IN: images.backend SINGLETONS: BGR RGB BGRA RGBA ABGR ARGB RGBX XRGB BGRX XBGR ; diff --git a/extra/images/bitmap/authors.txt b/basis/images/bitmap/authors.txt similarity index 100% rename from extra/images/bitmap/authors.txt rename to basis/images/bitmap/authors.txt diff --git a/extra/images/bitmap/bitmap-tests.factor b/basis/images/bitmap/bitmap-tests.factor similarity index 100% rename from extra/images/bitmap/bitmap-tests.factor rename to basis/images/bitmap/bitmap-tests.factor diff --git a/extra/images/bitmap/bitmap.factor b/basis/images/bitmap/bitmap.factor similarity index 100% rename from extra/images/bitmap/bitmap.factor rename to basis/images/bitmap/bitmap.factor diff --git a/extra/images/images.factor b/basis/images/images.factor similarity index 100% rename from extra/images/images.factor rename to basis/images/images.factor diff --git a/extra/images/tags.txt b/basis/images/tags.txt similarity index 100% rename from extra/images/tags.txt rename to basis/images/tags.txt diff --git a/extra/images/tiff/authors.txt b/basis/images/tiff/authors.txt similarity index 100% rename from extra/images/tiff/authors.txt rename to basis/images/tiff/authors.txt diff --git a/extra/images/tiff/tiff-tests.factor b/basis/images/tiff/tiff-tests.factor similarity index 100% rename from extra/images/tiff/tiff-tests.factor rename to basis/images/tiff/tiff-tests.factor diff --git a/extra/images/tiff/tiff.factor b/basis/images/tiff/tiff.factor similarity index 97% rename from extra/images/tiff/tiff.factor rename to basis/images/tiff/tiff.factor index dc40f648cc..dac071b4b4 100755 --- a/extra/images/tiff/tiff.factor +++ b/basis/images/tiff/tiff.factor @@ -1,10 +1,9 @@ ! Copyright (C) 2009 Doug Coleman. ! See http://factorcode.org/license.txt for BSD license. -USING: accessors combinators io io.encodings.binary io.files -kernel pack endian constructors sequences arrays -sorting.slots math.order math.parser prettyprint classes -io.binary assocs math math.bitwise byte-arrays grouping -images.backend ; +USING: accessors combinators io io.encodings.binary io.files kernel +pack endian constructors sequences arrays math.order math.parser +prettyprint classes io.binary assocs math math.bitwise byte-arrays +grouping images.backend ; IN: images.tiff TUPLE: tiff-image < image ; diff --git a/core/quotations/quotations-docs.factor b/core/quotations/quotations-docs.factor index f2629a36c4..2a03b7c74f 100644 --- a/core/quotations/quotations-docs.factor +++ b/core/quotations/quotations-docs.factor @@ -7,6 +7,9 @@ ARTICLE: "quotations" "Quotations" $nl "Concretely, a quotation is an immutable sequence of objects, some of which may be words, together with a block of machine code which may be executed to achieve the effect of evaluating the quotation. The machine code is generated by a fast non-optimizing quotation compiler which is always running and is transparent to the developer." $nl +"Quotations form a class of objects, however in most cases, methods should dispatch on " { $link callable } " instead, so that " { $link curry } " and " { $link compose } " values can participate." +{ $subsection quotation } +{ $subsection quotation? } "Quotations evaluate sequentially from beginning to end. Literals are pushed on the stack and words are executed. Details can be found in " { $link "evaluator" } "." $nl "Quotation literal syntax is documented in " { $link "syntax-quots" } "." diff --git a/extra/webapps/todo/todo.factor b/extra/webapps/todo/todo.factor index e1f6c8735a..6ef60c198f 100755 --- a/extra/webapps/todo/todo.factor +++ b/extra/webapps/todo/todo.factor @@ -106,7 +106,8 @@ todo "TODO" : ( -- responder ) todo-list new-dispatcher - "" add-responder + "list" add-responder + URL" /list" "" add-responder "view" add-responder "new" add-responder "edit" add-responder @@ -115,3 +116,52 @@ todo "TODO" { todo-list "todo" } >>template "view your todo list" >>description ; + +USING: furnace.auth.features.registration +furnace.auth.features.edit-profile +furnace.auth.features.deactivate-user +db.sqlite +furnace.alloy +io.servers.connection +io.sockets.secure ; + +: ( responder -- responder' ) + "Todo list" + "Todo list" >>name + allow-registration + allow-edit-profile + allow-deactivation ; + +: todo-db ( -- db ) "resource:todo.db" ; + +: init-todo-db ( -- ) + todo-db [ + init-furnace-tables + todo ensure-table + ] with-db ; + +: ( -- config ) + ! This is only suitable for testing! + + "resource:basis/openssl/test/dh1024.pem" >>dh-file + "resource:basis/openssl/test/server.pem" >>key-file + "password" >>password ; + +: ( -- responder ) + init-todo-db + + + todo-db ; + +: ( -- threaded-server ) + + >>secure-config + 8080 >>insecure + 8431 >>secure ; + +: run-todo ( -- ) + main-responder set-global + todo-db start-expiring + start-server ; + +MAIN: run-todo diff --git a/extra/webapps/todo/todo.xml b/extra/webapps/todo/todo.xml index f7500cdad2..00ed63560c 100644 --- a/extra/webapps/todo/todo.xml +++ b/extra/webapps/todo/todo.xml @@ -2,7 +2,14 @@ + + + + + + +