From 4489a747fcd91a37c6dbdf365b2b29ebb41f2b0f Mon Sep 17 00:00:00 2001 From: Len Kranendonk Date: Wed, 18 Aug 2004 18:01:54 +0000 Subject: [PATCH] Added htmlArea3 --- www/extras/htmlArea3/ChangeLog | 1185 +++++++++ www/extras/htmlArea3/dialog.js | 72 + www/extras/htmlArea3/htmlarea.css | 180 ++ www/extras/htmlArea3/htmlarea.js | 2175 +++++++++++++++++ www/extras/htmlArea3/images/ed_about.gif | Bin 0 -> 87 bytes .../htmlArea3/images/ed_align_center.gif | Bin 0 -> 69 bytes .../htmlArea3/images/ed_align_justify.gif | Bin 0 -> 69 bytes www/extras/htmlArea3/images/ed_align_left.gif | Bin 0 -> 69 bytes .../htmlArea3/images/ed_align_right.gif | Bin 0 -> 68 bytes www/extras/htmlArea3/images/ed_blank.gif | Bin 0 -> 56 bytes www/extras/htmlArea3/images/ed_charmap.gif | Bin 0 -> 143 bytes www/extras/htmlArea3/images/ed_color_bg.gif | Bin 0 -> 181 bytes www/extras/htmlArea3/images/ed_color_fg.gif | Bin 0 -> 171 bytes www/extras/htmlArea3/images/ed_copy.gif | Bin 0 -> 110 bytes www/extras/htmlArea3/images/ed_custom.gif | Bin 0 -> 67 bytes www/extras/htmlArea3/images/ed_cut.gif | Bin 0 -> 91 bytes www/extras/htmlArea3/images/ed_delete.gif | Bin 0 -> 90 bytes .../htmlArea3/images/ed_format_bold.gif | Bin 0 -> 74 bytes .../htmlArea3/images/ed_format_italic.gif | Bin 0 -> 77 bytes .../htmlArea3/images/ed_format_strike.gif | Bin 0 -> 78 bytes www/extras/htmlArea3/images/ed_format_sub.gif | Bin 0 -> 78 bytes www/extras/htmlArea3/images/ed_format_sup.gif | Bin 0 -> 77 bytes .../htmlArea3/images/ed_format_underline.gif | Bin 0 -> 85 bytes www/extras/htmlArea3/images/ed_help.gif | Bin 0 -> 70 bytes www/extras/htmlArea3/images/ed_hr.gif | Bin 0 -> 70 bytes www/extras/htmlArea3/images/ed_html.gif | Bin 0 -> 75 bytes www/extras/htmlArea3/images/ed_image.gif | Bin 0 -> 148 bytes .../htmlArea3/images/ed_indent_less.gif | Bin 0 -> 87 bytes .../htmlArea3/images/ed_indent_more.gif | Bin 0 -> 87 bytes .../htmlArea3/images/ed_left_to_right.gif | Bin 0 -> 89 bytes www/extras/htmlArea3/images/ed_link.gif | Bin 0 -> 97 bytes .../htmlArea3/images/ed_list_bullet.gif | Bin 0 -> 80 bytes www/extras/htmlArea3/images/ed_list_num.gif | Bin 0 -> 82 bytes www/extras/htmlArea3/images/ed_paste.gif | Bin 0 -> 139 bytes www/extras/htmlArea3/images/ed_redo.gif | Bin 0 -> 80 bytes .../htmlArea3/images/ed_right_to_left.gif | Bin 0 -> 88 bytes www/extras/htmlArea3/images/ed_save.gif | Bin 0 -> 143 bytes .../htmlArea3/images/ed_show_border.gif | Bin 0 -> 104 bytes www/extras/htmlArea3/images/ed_splitcel.gif | Bin 0 -> 143 bytes www/extras/htmlArea3/images/ed_undo.gif | Bin 0 -> 81 bytes .../htmlArea3/images/fullscreen_maximize.gif | Bin 0 -> 97 bytes .../htmlArea3/images/fullscreen_minimize.gif | Bin 0 -> 97 bytes www/extras/htmlArea3/images/insert_table.gif | Bin 0 -> 121 bytes www/extras/htmlArea3/index.html | 199 ++ www/extras/htmlArea3/lang/b5.js | 36 + www/extras/htmlArea3/lang/cz.js | 63 + www/extras/htmlArea3/lang/da.js | 38 + www/extras/htmlArea3/lang/de.js | 54 + www/extras/htmlArea3/lang/ee.js | 63 + www/extras/htmlArea3/lang/el.js | 75 + www/extras/htmlArea3/lang/en.js | 88 + www/extras/htmlArea3/lang/es.js | 51 + www/extras/htmlArea3/lang/fi.js | 46 + www/extras/htmlArea3/lang/fr.js | 61 + www/extras/htmlArea3/lang/gb.js | 36 + www/extras/htmlArea3/lang/he.js | 63 + www/extras/htmlArea3/lang/hu.js | 63 + www/extras/htmlArea3/lang/it.js | 54 + www/extras/htmlArea3/lang/ja-euc.js | 37 + www/extras/htmlArea3/lang/ja-jis.js | 37 + www/extras/htmlArea3/lang/ja-sjis.js | 37 + www/extras/htmlArea3/lang/ja-utf8.js | 37 + www/extras/htmlArea3/lang/lt.js | 55 + www/extras/htmlArea3/lang/lv.js | 55 + www/extras/htmlArea3/lang/nb.js | 36 + www/extras/htmlArea3/lang/nl.js | 90 + www/extras/htmlArea3/lang/no.js | 79 + www/extras/htmlArea3/lang/pl.js | 36 + www/extras/htmlArea3/lang/pt_br.js | 37 + www/extras/htmlArea3/lang/ro.js | 80 + www/extras/htmlArea3/lang/ru.js | 63 + www/extras/htmlArea3/lang/se.js | 38 + www/extras/htmlArea3/lang/si.js | 63 + www/extras/htmlArea3/lang/vn.js | 51 + www/extras/htmlArea3/license.txt | 30 + www/extras/htmlArea3/popupdiv.js | 369 +++ www/extras/htmlArea3/popups/about.html | 378 +++ www/extras/htmlArea3/popups/blank.html | 2 + www/extras/htmlArea3/popups/custom2.html | 35 + www/extras/htmlArea3/popups/editor_help.html | 16 + www/extras/htmlArea3/popups/fullscreen.html | 133 + www/extras/htmlArea3/popups/insert_image.html | 191 ++ www/extras/htmlArea3/popups/insert_table.html | 174 ++ www/extras/htmlArea3/popups/link.html | 142 ++ .../htmlArea3/popups/old-fullscreen.html | 131 + .../htmlArea3/popups/old_insert_image.html | 206 ++ www/extras/htmlArea3/popups/popup.js | 109 + www/extras/htmlArea3/popups/select_color.html | 347 +++ www/extras/htmlArea3/popupwin.js | 139 ++ www/extras/htmlArea3/reference.html | 523 ++++ www/extras/htmlArea3/release-notes.html | 165 ++ 91 files changed, 8523 insertions(+) create mode 100644 www/extras/htmlArea3/ChangeLog create mode 100644 www/extras/htmlArea3/dialog.js create mode 100644 www/extras/htmlArea3/htmlarea.css create mode 100644 www/extras/htmlArea3/htmlarea.js create mode 100644 www/extras/htmlArea3/images/ed_about.gif create mode 100644 www/extras/htmlArea3/images/ed_align_center.gif create mode 100644 www/extras/htmlArea3/images/ed_align_justify.gif create mode 100644 www/extras/htmlArea3/images/ed_align_left.gif create mode 100644 www/extras/htmlArea3/images/ed_align_right.gif create mode 100644 www/extras/htmlArea3/images/ed_blank.gif create mode 100644 www/extras/htmlArea3/images/ed_charmap.gif create mode 100644 www/extras/htmlArea3/images/ed_color_bg.gif create mode 100644 www/extras/htmlArea3/images/ed_color_fg.gif create mode 100644 www/extras/htmlArea3/images/ed_copy.gif create mode 100644 www/extras/htmlArea3/images/ed_custom.gif create mode 100644 www/extras/htmlArea3/images/ed_cut.gif create mode 100644 www/extras/htmlArea3/images/ed_delete.gif create mode 100644 www/extras/htmlArea3/images/ed_format_bold.gif create mode 100644 www/extras/htmlArea3/images/ed_format_italic.gif create mode 100644 www/extras/htmlArea3/images/ed_format_strike.gif create mode 100644 www/extras/htmlArea3/images/ed_format_sub.gif create mode 100644 www/extras/htmlArea3/images/ed_format_sup.gif create mode 100644 www/extras/htmlArea3/images/ed_format_underline.gif create mode 100644 www/extras/htmlArea3/images/ed_help.gif create mode 100644 www/extras/htmlArea3/images/ed_hr.gif create mode 100644 www/extras/htmlArea3/images/ed_html.gif create mode 100644 www/extras/htmlArea3/images/ed_image.gif create mode 100644 www/extras/htmlArea3/images/ed_indent_less.gif create mode 100644 www/extras/htmlArea3/images/ed_indent_more.gif create mode 100644 www/extras/htmlArea3/images/ed_left_to_right.gif create mode 100644 www/extras/htmlArea3/images/ed_link.gif create mode 100644 www/extras/htmlArea3/images/ed_list_bullet.gif create mode 100644 www/extras/htmlArea3/images/ed_list_num.gif create mode 100644 www/extras/htmlArea3/images/ed_paste.gif create mode 100644 www/extras/htmlArea3/images/ed_redo.gif create mode 100644 www/extras/htmlArea3/images/ed_right_to_left.gif create mode 100644 www/extras/htmlArea3/images/ed_save.gif create mode 100644 www/extras/htmlArea3/images/ed_show_border.gif create mode 100644 www/extras/htmlArea3/images/ed_splitcel.gif create mode 100644 www/extras/htmlArea3/images/ed_undo.gif create mode 100644 www/extras/htmlArea3/images/fullscreen_maximize.gif create mode 100644 www/extras/htmlArea3/images/fullscreen_minimize.gif create mode 100644 www/extras/htmlArea3/images/insert_table.gif create mode 100644 www/extras/htmlArea3/index.html create mode 100644 www/extras/htmlArea3/lang/b5.js create mode 100644 www/extras/htmlArea3/lang/cz.js create mode 100644 www/extras/htmlArea3/lang/da.js create mode 100644 www/extras/htmlArea3/lang/de.js create mode 100644 www/extras/htmlArea3/lang/ee.js create mode 100644 www/extras/htmlArea3/lang/el.js create mode 100644 www/extras/htmlArea3/lang/en.js create mode 100644 www/extras/htmlArea3/lang/es.js create mode 100644 www/extras/htmlArea3/lang/fi.js create mode 100644 www/extras/htmlArea3/lang/fr.js create mode 100644 www/extras/htmlArea3/lang/gb.js create mode 100644 www/extras/htmlArea3/lang/he.js create mode 100644 www/extras/htmlArea3/lang/hu.js create mode 100644 www/extras/htmlArea3/lang/it.js create mode 100644 www/extras/htmlArea3/lang/ja-euc.js create mode 100644 www/extras/htmlArea3/lang/ja-jis.js create mode 100644 www/extras/htmlArea3/lang/ja-sjis.js create mode 100644 www/extras/htmlArea3/lang/ja-utf8.js create mode 100644 www/extras/htmlArea3/lang/lt.js create mode 100644 www/extras/htmlArea3/lang/lv.js create mode 100644 www/extras/htmlArea3/lang/nb.js create mode 100644 www/extras/htmlArea3/lang/nl.js create mode 100644 www/extras/htmlArea3/lang/no.js create mode 100644 www/extras/htmlArea3/lang/pl.js create mode 100644 www/extras/htmlArea3/lang/pt_br.js create mode 100644 www/extras/htmlArea3/lang/ro.js create mode 100644 www/extras/htmlArea3/lang/ru.js create mode 100644 www/extras/htmlArea3/lang/se.js create mode 100644 www/extras/htmlArea3/lang/si.js create mode 100644 www/extras/htmlArea3/lang/vn.js create mode 100644 www/extras/htmlArea3/license.txt create mode 100644 www/extras/htmlArea3/popupdiv.js create mode 100644 www/extras/htmlArea3/popups/about.html create mode 100644 www/extras/htmlArea3/popups/blank.html create mode 100644 www/extras/htmlArea3/popups/custom2.html create mode 100644 www/extras/htmlArea3/popups/editor_help.html create mode 100644 www/extras/htmlArea3/popups/fullscreen.html create mode 100644 www/extras/htmlArea3/popups/insert_image.html create mode 100644 www/extras/htmlArea3/popups/insert_table.html create mode 100644 www/extras/htmlArea3/popups/link.html create mode 100644 www/extras/htmlArea3/popups/old-fullscreen.html create mode 100644 www/extras/htmlArea3/popups/old_insert_image.html create mode 100644 www/extras/htmlArea3/popups/popup.js create mode 100644 www/extras/htmlArea3/popups/select_color.html create mode 100644 www/extras/htmlArea3/popupwin.js create mode 100644 www/extras/htmlArea3/reference.html create mode 100644 www/extras/htmlArea3/release-notes.html diff --git a/www/extras/htmlArea3/ChangeLog b/www/extras/htmlArea3/ChangeLog new file mode 100644 index 000000000..8e185779e --- /dev/null +++ b/www/extras/htmlArea3/ChangeLog @@ -0,0 +1,1185 @@ +2004-02-17 Mihai Bazon + + * lang/el.js, plugins/ContextMenu/lang/el.js, plugins/TableOperations/lang/el.js: + updated headers + + * lang/no.js: updated (thanks havardw) + +2004-02-09 Mihai Bazon + + * plugins/EnterParagraphs/enter-paragraphs.js: + Plugin that enables Mozilla to create a

instead of
at ENTER. + Code contributed by Adam Wright. + + * htmlarea.js: code to call onKeyPress for plugins that define it + code that keeps single spaces as   + (thanks to hipikat @ IT forums (Adam Wright)) + + * ChangeLog: + ChangeLog is acutally automatically generated so there's no point keep it in CVS + +2004-02-08 Mihai Bazon + + * htmlarea.js: fixed possible bug + + * images/ed_align_center.gif, images/ed_align_justify.gif, images/ed_align_left.gif, images/ed_align_right.gif, images/ed_blank.gif, images/ed_charmap.gif, images/ed_color_bg.gif, images/ed_color_fg.gif, images/ed_copy.gif, images/ed_custom.gif, images/ed_cut.gif, images/ed_delete.gif, images/ed_format_bold.gif, images/ed_format_italic.gif, images/ed_format_strike.gif, images/ed_format_sub.gif, images/ed_format_sup.gif, images/ed_format_underline.gif, images/ed_help.gif, images/ed_hr.gif, images/ed_html.gif, images/ed_image.gif, images/ed_indent_less.gif, images/ed_indent_more.gif, images/ed_left_to_right.gif, images/ed_link.gif, images/ed_list_bullet.gif, images/ed_list_num.gif, images/ed_paste.gif, images/ed_redo.gif, images/ed_right_to_left.gif, images/ed_save.gif, images/ed_show_border.gif, images/ed_splitcel.gif, images/ed_undo.gif, images/fullscreen_maximize.gif, images/fullscreen_minimize.gif, images/insert_table.gif, images/ed_about.gif: + optimized images (thanks to Alexander Kandzior and OpenCMS group) + +2004-02-01 Mihai Bazon + + * project-config.xml: release candidate 1 + + * release-notes.html: updated release notes + + * examples/index.html, examples/makefile.xml: + added examples directory index + + * release-notes.html: fix + +2004-01-31 Mihai Bazon + + * makefile.xml: ensure correct file permissions + + * plugins/SpellChecker/spell-check-logic.cgi, plugins/SpellChecker/spell-check-ui.html, plugins/SpellChecker/spell-check-ui.js: + spell checker now reports some document information (such as total number of + words, number of mispelled words, number of suggestions, etc) + + * htmlarea.js: removed some custom attributes + + * plugins/SpellChecker/spell-check-ui.js: + fixed bug (frame scroll in IE) + +2004-01-30 Mihai Bazon + + * ChangeLog, release-notes.html: updated release notes, changelog + + * plugins/SpellChecker/readme-tech.html: + updated text about Aspell Unicode support + + * plugins/SpellChecker/spell-check-style.css: - lorem ipsum + + * plugins/SpellChecker/spell-check-logic.cgi: - optimization + + * plugins/SpellChecker/spell-check-logic.cgi: + - bugfix (removed tags) + + * plugins/SpellChecker/spell-check-logic.cgi: + bleah.. this version seems to be safer; no mo' HTML::Parser; DOM rulz. + + * plugins/SpellChecker/spell-check-logic.cgi: + seems to be better now :-\ hell knows how perl & unicode works :-/ + + * plugins/SpellChecker/spell-check-logic.cgi, plugins/SpellChecker/spell-check-ui.js: + - big performance improvement (suggestion is now passed only once for each + mispelled word) + - bugs fixed (text already corrected in Unicode is now correctly decoded) + + * plugins/SpellChecker/lang/en.js: - added word "Revert" + + * plugins/SpellChecker/spell-checker.js: - lorem ipsum + - window is a bit higher now (450px) + + * plugins/SpellChecker/spell-check-ui.js: + - fixed IE bug ("undefined is undefined or undefined", or something..) + - the highlighted word will now remain in view (window scrolls if necessary) + - functionality for "Revert" + - (tried to) eliminate some of the screen blinking in Mozilla + - select the current dictionary on first display + + * plugins/SpellChecker/spell-check-ui.html: + added "Revert" button (reverts the current word to the mispelled original) + + * plugins/SpellChecker/spell-check-style.css: *** empty log message *** + + * plugins/SpellChecker/spell-check-logic.cgi: + - fixed (hopefully) unicode support (by the way, it seems that Aspell _does_ + in fact know Unicode!!) + - remembers the selected dictionary in a cookie + - removed debug code + +2004-01-28 Mihai Bazon + + * index.html: updated main page + + * release-notes.html: updated release notes + + * htmlarea.js: jscrunch-safe + + * popups/about.html: + stop tab click event so that they don't get selected + + * reference.html: some parts updated + + * popups/about.html, examples/2-areas.html, examples/context-menu.html, examples/core.html, examples/css.html, examples/full-page.html, examples/fully-loaded.html, examples/spell-checker.html, examples/table-operations.html, plugins/SpellChecker/readme-tech.html, ChangeLog, dialog.js, htmlarea.js, index.html, license.txt, popupwin.js, release-notes.html: + ChangeLog updated; copyright years/info updated + +2004-01-27 Mihai Bazon + + * htmlarea.js: + Included an workaround for a strange IE problem: IE's getElementById can + return a field having the _name_ attribute equal to the searched ID, even if + it's not having any ID at all. This can sometimes lead to taking a + different field (even if it's not a textarea) as the replacement field which + trashes the whole layout, look, feel, and functionality :-( Need to say it + again, IE SUCKS. + + Thanks goes to Mike Dick for the bug report and for the patch ;-) + +2004-01-18 Mihai Bazon + + * plugins/SpellChecker/spell-check-ui.js: + fixed bug (thanks Bill Sechrist for report): + when you "ignore"-ed the last mispelled word, no changes were applied + +2004-01-16 Mihai Bazon + + * htmlarea.js: border: 0px on body,html in pageStyle + + * popups/about.html: report userAgent in plugins tab + +2004-01-12 Mihai Bazon + + * lang/ru.js: updated (thanks to Yulya Shtyryakova) + +2004-01-03 Mihai Bazon + + * plugins/ContextMenu/lang/de.js: updated + +2004-01-02 Mihai Bazon + + * plugins/ContextMenu/lang/de.js: + DE translation, thanks to Martin Jaggi + +2003-12-22 Mihai Bazon + + * lang/ee.js: Estonian translation + +2003-12-05 Mihai Bazon + + * htmlarea.js: word cleaner: now it actually works ;-) + + * plugins/ContextMenu/lang/el.js, lang/el.js, plugins/TableOperations/lang/el.js: + added Greek translation (thanks to Dimitris Glezos) + + * htmlarea.js: + call an onGenerate handler, if found on the editor object + + * popups/about.html, popups/popup.js: updated about box + + * plugins/SpellChecker/spell-check-ui.js: *** empty log message *** + + * plugins/ContextMenu/context-menu.js: + open the normal insert_link dialog on modify link + +2003-11-28 Mihai Bazon + + * htmlarea.css: -moz-opacity got back + + * popups/about.html: *** empty log message *** + + * htmlarea.js: added Word cleaner code (thanks weeezl) + fixed the bug concerning the url of relative link/images + +2003-11-24 Mihai Bazon + + * plugins/CSS/css.js: + allows updation of parent element's class (no span). thanks goes to Michael (pepl @ IT forums) + +2003-11-22 Mihai Bazon + + * plugins/ContextMenu/lang/nl.js, plugins/TableOperations/lang/nl.js: + translation thanks to mmcw /IT forums + + * lang/nl.js: updated (thanks to mmcw /IT forums) + +2003-11-21 Mihai Bazon + + * makefile.xml: added ChangeLog to project dist + + * ChangeLog: Updated ChangeLog + + * examples/context-menu.html, examples/fully-loaded.html, examples/pieng.png, index.html, plugins/ContextMenu/1.pl, plugins/ContextMenu/context-menu.js, plugins/ContextMenu/lang/en.js, plugins/ContextMenu/lang/makefile.xml, plugins/ContextMenu/makefile.xml, plugins/ContextMenu/menu.css, plugins/makefile.xml: + Added ContextMenu plugin (work sponsored by American Bible Society) + +2003-11-11 Mihai Bazon + + * lang/en.js, lang/ro.js: support for the link dialog + + * plugins/FullPage/popups/docprop.html, popups/popup.js: + support for I18N of core dialogs, added function to select a value in a + + + diff --git a/www/extras/htmlArea3/popups/insert_image.html b/www/extras/htmlArea3/popups/insert_image.html new file mode 100644 index 000000000..1a0e9604a --- /dev/null +++ b/www/extras/htmlArea3/popups/insert_image.html @@ -0,0 +1,191 @@ + + + + Insert Image + + + + + + + + + + + +

Insert Image
+ +
+ + + + + + + + + + + + + +
Image URL: + +
Alternate text:
+ +

+ +

+Layout + +
+ +
Alignment:
+ + +

+ +

Border thickness:
+ + +
+ +
+ +
+Spacing + +
+ +
Horizontal:
+ + +

+ +

Vertical:
+ + +
+ +
+
+ + + + + +
+ Image Preview:
+ +
+
+ +
+
+ + diff --git a/www/extras/htmlArea3/popups/insert_table.html b/www/extras/htmlArea3/popups/insert_table.html new file mode 100644 index 000000000..508dbf8e1 --- /dev/null +++ b/www/extras/htmlArea3/popups/insert_table.html @@ -0,0 +1,174 @@ + + + + Insert Table + + + + + + + + + + + +
Insert Table
+ +
+ + + + + + + + + + + + + + + + + + + +
Rows:
Cols:Width:
+ +

+ +

+Layout + +
+ +
Alignment:
+ + +

+ +

Border thickness:
+ + +
+ +
+ +
+Spacing + +
+ +
Cell spacing:
+ + +

+ +

Cell padding:
+ + +
+ +
+ +
+ + +
+ +
+ + + diff --git a/www/extras/htmlArea3/popups/link.html b/www/extras/htmlArea3/popups/link.html new file mode 100644 index 000000000..41780e4c5 --- /dev/null +++ b/www/extras/htmlArea3/popups/link.html @@ -0,0 +1,142 @@ + + + + Insert/Modify Link + + + + + + + + +
Insert/Modify Link
+ + + + + + + + + + + + + + +
URL:
Title (tooltip):
Target: + +
+ +
+ + +
+ + + diff --git a/www/extras/htmlArea3/popups/old-fullscreen.html b/www/extras/htmlArea3/popups/old-fullscreen.html new file mode 100644 index 000000000..7c00d916c --- /dev/null +++ b/www/extras/htmlArea3/popups/old-fullscreen.html @@ -0,0 +1,131 @@ + +Fullscreen Editor + + + + + + +
+ +
+ + \ No newline at end of file diff --git a/www/extras/htmlArea3/popups/old_insert_image.html b/www/extras/htmlArea3/popups/old_insert_image.html new file mode 100644 index 000000000..613f46013 --- /dev/null +++ b/www/extras/htmlArea3/popups/old_insert_image.html @@ -0,0 +1,206 @@ + + + + + + + +Insert Image + + + + + +
Image URL:
+ + +
Alternate Text:
+ + +
+Layout +
+ +
+Spacing +
+ +
Alignment:
+ + +
Horizontal:
+ + +
Border Thickness:
+ + +
Vertical:
+ + + + + + + \ No newline at end of file diff --git a/www/extras/htmlArea3/popups/popup.js b/www/extras/htmlArea3/popups/popup.js new file mode 100644 index 000000000..15f526865 --- /dev/null +++ b/www/extras/htmlArea3/popups/popup.js @@ -0,0 +1,109 @@ +// htmlArea v3.0 - Copyright (c) 2002, 2003 interactivetools.com, inc. +// This copyright notice MUST stay intact for use (see license.txt). +// +// Portions (c) dynarch.com, 2003 +// +// A free WYSIWYG editor replacement for + + +

Where can I find out more info, download the latest version and talk to +other HTMLArea users?

+ +

You can find out more about HTMLArea and download the latest version on +the HTMLArea +homepage and you can talk to other HTMLArea users and post any comments +or suggestions you have in the HTMLArea forum.

+ +

Keyboard shortcuts

+ +

The editor provides the following key combinations:

+ +
    +
  • CTRL-A -- select all
  • +
  • CTRL-B -- bold
  • +
  • CTRL-I -- italic
  • +
  • CTRL-U -- underline
  • +
  • CTRL-S -- strikethrough
  • +
  • CTRL-L -- justify left
  • +
  • CTRL-E -- justify center
  • +
  • CTRL-R -- justify right
  • +
  • CTRL-J -- justify full
  • +
  • CTRL-1 .. CTRL-6 -- headings (<h1> .. <h6>)
  • +
  • CTRL-0 (zero) -- clean content pasted from Word
  • +
+ +

Installation

+ +

How do I add HTMLArea to my web page?

+ +

It's easy. First you need to upload HTMLArea files to your website. +Just follow these steps.

+ +
    +
  1. Download the latest version from the htmlArea + homepage.
  2. +
  3. Unzip the files onto your local computer (making sure to maintain the + directory structure contained in the zip).
  4. +
  5. Create a new folder on your website called /htmlarea/ (make sure it's + NOT inside the cgi-bin).
  6. +
  7. Transfer all the HTMLArea files from your local computer into the + /htmlarea/ folder on your website.
  8. +
  9. Open the example page /htmlarea/examples/core.html with your browser to make + sure everything works.
  10. +
+ +

Once htmlArea is on your website all you need to do is add some +JavaScript to any pages that you want to add WYSIWYG editors to. Here's how +to do that.

+ +
    + +
  1. Define some global variables. "_editor_url" has to be the absolute + URL where HTMLArea resides within your + website; as we discussed, this would be “/htmlarea/”. "_editor_lang" must + be the language code in which you want HTMLArea to appear. This defaults + to "en" (English); for a list of supported languages, please look into + the "lang" subdirectory in the distribution. +
    <script type="text/javascript">
    +   _editor_url = "/htmlarea/";
    +   _editor_lang = "en";
    +</script>
    + +
  2. Include the "htmlarea.js" script: +
    <script type="text/javascript" src="/htmlarea/htmlarea.js"></script>
    +
  3. + +
  4. If you want to change all your <textarea>-s into + HTMLArea-s then you can use the simplest way to create HTMLArea:

    +
    <script type="text/javascript" defer="1">
    +    HTMLArea.replaceAll();
    +</script>
    +

    Note: you can also add the + HTMLArea.replaceAll() code to the onload + event handler for the body element, if you find it more appropriate.

    + +

    A different approach, if you have more than one textarea and only want + to change one of them, is to use HTMLArea.replace("id") -- + pass the id of your textarea. Do not use the + name attribute anymore, it's not a standard solution!

    + +
+ +

This section applies to HTMLArea-3.0 release candidate 1 or later; prior +to this version, one needed to include more files; however, now HTMLArea is +able to include other files too (such as stylesheet, language definition +file, etc.) so you only need to define the editor path and load +"htmlarea.js". Nice, eh? ;-)

+ +

I want to change the editor settings, how do I do that?

+ +

While it's true that all you need is one line of JavaScript to create an +htmlArea WYSIWYG editor, you can also specify more config settings in the +code to control how the editor works and looks. Here's an example of some of +the available settings:

+ +
var config = new HTMLArea.Config(); // create a new configuration object
+                                    // having all the default values
+config.width = '90%';
+config.height = '200px';
+
+// the following sets a style for the page body (black text on yellow page)
+// and makes all paragraphs be bold by default
+config.pageStyle =
+  'body { background-color: yellow; color: black; font-family: verdana,sans-serif } ' +
+  'p { font-width: bold; } ';
+
+// the following replaces the textarea with the given id with a new
+// HTMLArea object having the specified configuration
+HTMLArea.replace('id', config);
+ +

Important: It's recommended that you add +custom features and configuration to a separate file. This will ensure you +that when we release a new official version of HTMLArea you'll have less +trouble upgrading it.

+ +

How do I customize the toolbar?

+ +

Using the configuration object introduced above allows you to completely +control what the toolbar contains. Following is an example of a one-line, +customized toolbar, much simpler than the default one:

+ +
var config = new HTMLArea.Config();
+config.toolbar = [
+  ['fontname', 'space',
+   'fontsize', 'space',
+   'formatblock', 'space',
+   'bold', 'italic', 'underline']
+];
+HTMLArea.replace('id', config);
+ +

The toolbar is an Array of Array objects. Each array in the toolbar +defines a new line. The default toolbar looks like this:

+ +
config.toolbar = [
+[ "fontname", "space",
+  "fontsize", "space",
+  "formatblock", "space",
+  "bold", "italic", "underline", "separator",
+  "strikethrough", "subscript", "superscript", "separator",
+  "copy", "cut", "paste", "space", "undo", "redo" ],
+		
+[ "justifyleft", "justifycenter", "justifyright", "justifyfull", "separator",
+  "insertorderedlist", "insertunorderedlist", "outdent", "indent", "separator",
+  "forecolor", "hilitecolor", "textindicator", "separator",
+  "inserthorizontalrule", "createlink", "insertimage", "inserttable", "htmlmode", "separator",
+  "popupeditor", "separator", "showhelp", "about" ]
+];
+ +

Except three strings, all others in the examples above need to be defined +in the config.btnList object (detailed a bit later in this +document). The three exceptions are: 'space', 'separator' and 'linebreak'. +These three have the following meaning, and need not be present in +btnList:

+ +
    +
  • 'space' -- Inserts a space of 5 pixels (the width is configurable by external + CSS) at the current + position in the toolbar.
  • +
  • 'separator' -- Inserts a small vertical separator, for visually grouping related + buttons.
  • +
  • 'linebreak' -- Starts a new line in the toolbar. Subsequent controls will be + inserted on the new line.
  • +
+ +

Important: It's recommended that you add +custom features and configuration to a separate file. This will ensure you +that when we release a new official version of HTMLArea you'll have less +trouble upgrading it.

+ +

How do I create custom buttons?

+ +

By design, the toolbar is easily extensible. For adding a custom button +one needs to follow two steps.

+ +

1. Register the button in config.btnList.

+ +

For each button in the toolbar, HTMLArea needs to know the following +information:

+
    +
  • a name for it (we call it the ID of the button);
  • +
  • the path to an image to be displayed in the toolbar;
  • +
  • a tooltip for it;
  • +
  • whether the button is enabled or not in text mode;
  • +
  • what to do when the button is clicked;
  • +
+

You need to provide all this information for registering a new button +too. The button ID can be any string identifier and it's used when +defining the toolbar, as you saw above. We recommend starting +it with "my-" so that it won't clash with the standard ID-s (those from +the default toolbar).

+ +

Register button example #1

+ +
// get a default configuration
+var config = new HTMLArea.Config();
+// register the new button using Config.registerButton.
+// parameters:        button ID,   tooltip,          image,           textMode,
+config.registerButton("my-hilite", "Highlight text", "my-hilite.gif", false,
+// function that gets called when the button is clicked
+  function(editor, id) {
+    editor.surroundHTML('<span class="hilite">', '</span>');
+  }
+);
+ +

An alternate way of calling registerButton is exemplified above. Though +the code might be a little bit larger, using this form makes your code more +maintainable. It doesn't even needs comments as it's pretty clear.

+ +

Register button example #2

+ +
var config = new HTMLArea.Config();
+config.registerButton({
+  id        : "my-hilite",
+  tooltip   : "Highlight text",
+  image     : "my-hilite.gif",
+  textMode  : false,
+  action    : function(editor, id) {
+                editor.surroundHTML('<span class="hilite">', '</span>');
+              }
+});
+ +

You might notice that the "action" function receives two parameters: +editor and id. In the examples above we only used the +editor parameter. But it could be helpful for you to understand +both:

+ +
    +
  • editor is a reference to the HTMLArea object. Since our entire + code now has an OOP-like + design, you need to have a reference to + the editor object in order to do things with it. In previous versions of + HTMLArea, in order to identify the object an ID was used -- the ID of the + HTML element. In this version ID-s are no longer necessary.
  • + +
  • id is the button ID. Wondering why is this useful? Well, you + could use the same handler function (presuming that it's not an anonymous + function like in the examples above) for more buttons. You can see an example a bit later in this document.
  • +
+ +

2. Inserting it into the toolbar

+ +

At this step you need to specify where in the toolbar to insert the +button, or just create the whole toolbar again as you saw in the previous +section. You use the button ID, as shown in the examples of customizing the +toolbar in the previous section.

+ +

For the sake of completion, following there are another examples.

+ +

Append your button to the default toolbar

+ +
config.toolbar.push([ "my-hilite" ]);
+ +

Customized toolbar

+ +
config.toolbar = [
+  ['fontname', 'space',
+   'fontsize', 'space',
+   'formatblock', 'space',
+   'separator', 'my-hilite', 'separator', 'space', // here's your button
+   'bold', 'italic', 'underline', 'space']
+];
+ +

Note: in the example above our new button is +between two vertical separators. But this is by no means required. You can +put it wherever you like. Once registered in the btnList (step 1) your custom button behaves just like a default +button.

+ +

Important: It's recommended that you add +custom features and configuration to a separate file. This will ensure you +that when we release a new official version of HTMLArea you'll have less +trouble upgrading it.

+ +

A complete example

+ +

Please note that it is by no means necessary to include the following +code into the htmlarea.js file. On the contrary, it might not work there. +The configuration system is designed such that you can always customize the +editor from outside files, thus keeping the htmlarea.js file +intact. This will make it easy for you to upgrade your HTMLArea when we +release a new official version. OK, I promise it's the last time I said +this. ;)

+ +
// All our custom buttons will call this function when clicked.
+// We use the buttonId parameter to determine what button
+// triggered the call.
+function clickHandler(editor, buttonId) {
+  switch (buttonId) {
+    case "my-toc":
+      editor.insertHTML("<h1>Table Of Contents</h1>");
+      break;
+    case "my-date":
+      editor.insertHTML((new Date()).toString());
+      break;
+    case "my-bold":
+      editor.execCommand("bold");
+      editor.execCommand("italic");
+      break;
+    case "my-hilite":
+      editor.surroundHTML("<span class=\"hilite\">", "</span>");
+      break;
+  }
+};
+
+// Create a new configuration object
+var config = new HTMLArea.Config();
+
+// Register our custom buttons
+config.registerButton("my-toc",  "Insert TOC", "my-toc.gif", false, clickHandler);
+config.registerButton("my-date", "Insert date/time", "my-date.gif", false, clickHandler);
+config.registerButton("my-bold", "Toggle bold/italic", "my-bold.gif", false, clickHandler);
+config.registerButton("my-hilite", "Hilite selection", "my-hilite.gif", false, clickHandler);
+
+// Append the buttons to the default toolbar
+config.toolbar.push(["linebreak", "my-toc", "my-date", "my-bold", "my-hilite"]);
+
+// Replace an existing textarea with an HTMLArea object having the above config.
+HTMLArea.replace("textAreaID", config);
+ + +
+
© InteractiveTools.com 2002-2004. +
dynarch.com 2003-2004
+HTMLArea v3.0 developed by Mihai Bazon. +
+Documentation written by Mihai Bazon. +
+ Last modified: Wed Jan 28 12:18:23 EET 2004 + + diff --git a/www/extras/htmlArea3/release-notes.html b/www/extras/htmlArea3/release-notes.html new file mode 100644 index 000000000..f2200d50e --- /dev/null +++ b/www/extras/htmlArea3/release-notes.html @@ -0,0 +1,165 @@ + + + + HTMLArea-3.0-rc1 release notes + + + + + +

HTMLArea-3.0-rc1 release notes

+ +

This release was compiled on Mar 1, 2004 [19:37] GMT.

+ +

3.0-rc1

+ +

Changes since 3.0-Beta:

+ +
    +
  • + New plugins +
      +
    • + ContextMenu plugin (provides a nice context menu with common + operations, including table ops, link ops, etc.) +
    • +
    • + CSS plugin (provides an easy way to insert/change CSS classes) +
    • +
    • + FullPage plugin (allows HTMLArea to edit a whole HTML file, + not only the content within <body>.) +
    • +
    +
  • +
  • + Changes in the SpellChecker plugin +
      +
    • + Many bugfixes: now it works ;-) Fully Unicode-safe. +
    • +
    • + Speed and bandwidth optimization: reports the list of + suggestions only once for each mispelled word; this helps + in cases where you have, for instance, the word “HTMLArea” + in 10 places all over the document; the list of + suggestions for it--which is kind of huge--will only be + included once. +
    • +
    • + User interface improvements: the highlighted word will + remain in view; in cases where it's normally outside, the + window will be scrolled to it. +
    • +
    • + Added a "Revert" button for those that change their minds ;-) +
    • +
    • + Added a "Info" button which reports information about the + document, retrieved by the server-side spell checker: + total number of words, total number of mispelled words, + number of suggestions made, spell check time, etc. More + can be easily added. FIXME: this part + is not yet internationalized. +
    • +
    • + The server-side spell checker now uses XML::DOM instead of + HTML::Parser, which means that it will be unable to parse + “tag-soup” HTML. It needs valid code. Usually HTMLArea + generates valid code, but on rare occasions it might fail + and the spell checker will report a gross error message. + This gonna have to be fixed, but instead of making the + spell checker accept invalid HTML I prefer to make + HTMLArea generate valid code, so changes are to be done in + other places ;-) +
    • +
    +
  • +
  • + Changes in the core editor +
      +
    • + Easier to setup: you only need to load + htmlarea.js; other scripts will be loaded + automatically. Documentation + and examples updated. +
    • +
    • + Better plugin support (they register information about + themselves with the editor; can register event handlers for + the editor, etc.) +
    • +
    • + New about box; check it out, it's cool ;-) +
    • +
    • + Word cleaner (can be enabled to automatically kill Word crap + on paste (see Config.killWordOnPaste); otherwise accessible by + pressing CTRL-0 in the editor; a toolbar button will come up + soon) +
    • +
    • + Image preview in "insert image" dialog. Also allows + modification of current image, if selected. +
    • +
    • + New "insert link" dialog, allows target and title + specification, allows editing links. +
    • +
    • + Implemented support for text direction (left-to-right or + right-to-left). +
    • +
    • + Lots of bug fixes! ... and more, I guess ;-) an + automatically generated change log + is now available. +
    • +
    +
  • +
+ +

I don't have the power to go through the bug +system at SourceForge + now. Some of the bugs reported there may be fixed; I'll update + their status, some other time. If you reported bugs there and now + find them to be fixed, please let me know.

+ +

3.0-Beta

+ +

Changes since 3.0-Alpha:

+ +
    + +
  • Performance improvements.
  • + +
  • Many bugs fixed.
  • + +
  • Plugin infrastructure.
  • + +
  • TableOperations plugin.
  • + +
  • SpellChecker plugin.
  • + +
  • Status bar.
  • + +
  • API for registering custom buttons and drop-down boxes in the + toolbar.
  • + +
  • Toolbar can contain text labels.
  • + +
  • Cut, copy, paste, undo, redo buttons.
  • + +
+
+
Mihai Bazon
+ + Last modified: Sun Feb 1 13:16:10 EET 2004 + + + + +