editarea-rails 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/LICENSE.txt +22 -0
- data/README.md +31 -0
- data/lib/editarea-rails.rb +8 -0
- data/lib/editarea-rails/version.rb +5 -0
- data/vendor/assets/images/autocompletion.gif +0 -0
- data/vendor/assets/images/close.gif +0 -0
- data/vendor/assets/images/fullscreen.gif +0 -0
- data/vendor/assets/images/go_to_line.gif +0 -0
- data/vendor/assets/images/help.gif +0 -0
- data/vendor/assets/images/highlight.gif +0 -0
- data/vendor/assets/images/load.gif +0 -0
- data/vendor/assets/images/move.gif +0 -0
- data/vendor/assets/images/newdocument.gif +0 -0
- data/vendor/assets/images/opacity.png +0 -0
- data/vendor/assets/images/plugins/charmap/charmap.gif +0 -0
- data/vendor/assets/images/plugins/test/css/test.css +3 -0
- data/vendor/assets/images/plugins/test/images/Thumbs.db +0 -0
- data/vendor/assets/images/plugins/test/images/test.gif +0 -0
- data/vendor/assets/images/plugins/test/langs/bg.js +10 -0
- data/vendor/assets/images/plugins/test/langs/cs.js +4 -0
- data/vendor/assets/images/plugins/test/langs/de.js +4 -0
- data/vendor/assets/images/plugins/test/langs/dk.js +4 -0
- data/vendor/assets/images/plugins/test/langs/en.js +4 -0
- data/vendor/assets/images/plugins/test/langs/eo.js +4 -0
- data/vendor/assets/images/plugins/test/langs/es.js +4 -0
- data/vendor/assets/images/plugins/test/langs/fr.js +4 -0
- data/vendor/assets/images/plugins/test/langs/hr.js +4 -0
- data/vendor/assets/images/plugins/test/langs/it.js +4 -0
- data/vendor/assets/images/plugins/test/langs/ja.js +4 -0
- data/vendor/assets/images/plugins/test/langs/mk.js +4 -0
- data/vendor/assets/images/plugins/test/langs/nl.js +4 -0
- data/vendor/assets/images/plugins/test/langs/pl.js +4 -0
- data/vendor/assets/images/plugins/test/langs/pt.js +4 -0
- data/vendor/assets/images/plugins/test/langs/ru.js +4 -0
- data/vendor/assets/images/plugins/test/langs/sk.js +4 -0
- data/vendor/assets/images/plugins/test/langs/zh.js +4 -0
- data/vendor/assets/images/plugins/test/test.js +110 -0
- data/vendor/assets/images/plugins/test/test2.js +1 -0
- data/vendor/assets/images/processing.gif +0 -0
- data/vendor/assets/images/redo.gif +0 -0
- data/vendor/assets/images/reset_highlight.gif +0 -0
- data/vendor/assets/images/save.gif +0 -0
- data/vendor/assets/images/search.gif +0 -0
- data/vendor/assets/images/smooth_selection.gif +0 -0
- data/vendor/assets/images/spacer.gif +0 -0
- data/vendor/assets/images/statusbar_resize.gif +0 -0
- data/vendor/assets/images/undo.gif +0 -0
- data/vendor/assets/images/word_wrap.gif +0 -0
- data/vendor/assets/javascripts/autocompletion.js +491 -0
- data/vendor/assets/javascripts/edit_area.js +527 -0
- data/vendor/assets/javascripts/edit_area_full.js +38 -0
- data/vendor/assets/javascripts/edit_area_functions.js +1202 -0
- data/vendor/assets/javascripts/edit_area_loader.js +1081 -0
- data/vendor/assets/javascripts/elements_functions.js +336 -0
- data/vendor/assets/javascripts/highlight.js +407 -0
- data/vendor/assets/javascripts/keyboard.js +145 -0
- data/vendor/assets/javascripts/langs/bg.js +54 -0
- data/vendor/assets/javascripts/langs/cs.js +48 -0
- data/vendor/assets/javascripts/langs/de.js +48 -0
- data/vendor/assets/javascripts/langs/dk.js +48 -0
- data/vendor/assets/javascripts/langs/en.js +48 -0
- data/vendor/assets/javascripts/langs/eo.js +48 -0
- data/vendor/assets/javascripts/langs/es.js +48 -0
- data/vendor/assets/javascripts/langs/fi.js +48 -0
- data/vendor/assets/javascripts/langs/fr.js +48 -0
- data/vendor/assets/javascripts/langs/hr.js +48 -0
- data/vendor/assets/javascripts/langs/it.js +48 -0
- data/vendor/assets/javascripts/langs/ja.js +48 -0
- data/vendor/assets/javascripts/langs/mk.js +48 -0
- data/vendor/assets/javascripts/langs/nl.js +48 -0
- data/vendor/assets/javascripts/langs/pl.js +48 -0
- data/vendor/assets/javascripts/langs/pt.js +48 -0
- data/vendor/assets/javascripts/langs/ru.js +48 -0
- data/vendor/assets/javascripts/langs/sk.js +48 -0
- data/vendor/assets/javascripts/langs/zh.js +48 -0
- data/vendor/assets/javascripts/manage_area.js +623 -0
- data/vendor/assets/javascripts/plugins/charmap/charmap.js +90 -0
- data/vendor/assets/javascripts/plugins/charmap/jscripts/map.js +373 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/bg.js +12 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/cs.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/de.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/dk.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/en.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/eo.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/es.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/fr.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/hr.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/it.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/ja.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/mk.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/nl.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/pl.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/pt.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/ru.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/sk.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/langs/zh.js +6 -0
- data/vendor/assets/javascripts/plugins/charmap/popup.html +24 -0
- data/vendor/assets/javascripts/plugins/test/langs/bg.js +10 -0
- data/vendor/assets/javascripts/plugins/test/langs/cs.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/de.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/dk.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/en.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/eo.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/es.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/fr.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/hr.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/it.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/ja.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/mk.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/nl.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/pl.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/pt.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/ru.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/sk.js +4 -0
- data/vendor/assets/javascripts/plugins/test/langs/zh.js +4 -0
- data/vendor/assets/javascripts/plugins/test/test.js +110 -0
- data/vendor/assets/javascripts/plugins/test/test2.js +1 -0
- data/vendor/assets/javascripts/reg_syntax.js +166 -0
- data/vendor/assets/javascripts/reg_syntax/basic.js +70 -0
- data/vendor/assets/javascripts/reg_syntax/brainfuck.js +45 -0
- data/vendor/assets/javascripts/reg_syntax/c.js +63 -0
- data/vendor/assets/javascripts/reg_syntax/coldfusion.js +120 -0
- data/vendor/assets/javascripts/reg_syntax/cpp.js +66 -0
- data/vendor/assets/javascripts/reg_syntax/css.js +85 -0
- data/vendor/assets/javascripts/reg_syntax/html.js +51 -0
- data/vendor/assets/javascripts/reg_syntax/java.js +57 -0
- data/vendor/assets/javascripts/reg_syntax/js.js +94 -0
- data/vendor/assets/javascripts/reg_syntax/pas.js +83 -0
- data/vendor/assets/javascripts/reg_syntax/perl.js +88 -0
- data/vendor/assets/javascripts/reg_syntax/php.js +157 -0
- data/vendor/assets/javascripts/reg_syntax/python.js +145 -0
- data/vendor/assets/javascripts/reg_syntax/robotstxt.js +25 -0
- data/vendor/assets/javascripts/reg_syntax/ruby.js +68 -0
- data/vendor/assets/javascripts/reg_syntax/sql.js +56 -0
- data/vendor/assets/javascripts/reg_syntax/tsql.js +88 -0
- data/vendor/assets/javascripts/reg_syntax/vb.js +53 -0
- data/vendor/assets/javascripts/reg_syntax/xml.js +57 -0
- data/vendor/assets/javascripts/regexp.js +139 -0
- data/vendor/assets/javascripts/resize_area.js +73 -0
- data/vendor/assets/javascripts/search_replace.js +174 -0
- data/vendor/assets/stylesheets/edit_area.css +530 -0
- data/vendor/assets/stylesheets/plugins/charmap/css/charmap.css +64 -0
- data/vendor/assets/stylesheets/plugins/test/css/test.css +3 -0
- metadata +210 -0
@@ -0,0 +1,139 @@
|
|
1
|
+
/*EditArea.prototype.comment_or_quotes= function(v0, v1, v2, v3, v4,v5,v6,v7,v8,v9, v10){
|
2
|
+
new_class="quotes";
|
3
|
+
if(v6 && v6 != undefined && v6!="")
|
4
|
+
new_class="comments";
|
5
|
+
return "µ__"+ new_class +"__µ"+v0+"µ_END_µ";
|
6
|
+
|
7
|
+
};*/
|
8
|
+
|
9
|
+
/* EditArea.prototype.htmlTag= function(v0, v1, v2, v3, v4,v5,v6,v7,v8,v9, v10){
|
10
|
+
res="<span class=htmlTag>"+v2;
|
11
|
+
alert("v2: "+v2+" v3: "+v3);
|
12
|
+
tab=v3.split("=");
|
13
|
+
attributes="";
|
14
|
+
if(tab.length>1){
|
15
|
+
attributes="<span class=attribute>"+tab[0]+"</span>=";
|
16
|
+
for(i=1; i<tab.length-1; i++){
|
17
|
+
cut=tab[i].lastIndexOf(" ");
|
18
|
+
attributes+="<span class=attributeVal>"+tab[i].substr(0,cut)+"</span>";
|
19
|
+
attributes+="<span class=attribute>"+tab[i].substr(cut)+"</span>=";
|
20
|
+
}
|
21
|
+
attributes+="<span class=attributeVal>"+tab[tab.length-1]+"</span>";
|
22
|
+
}
|
23
|
+
res+=attributes+v5+"</span>";
|
24
|
+
return res;
|
25
|
+
};*/
|
26
|
+
|
27
|
+
// determine if the selected text if a comment or a quoted text
|
28
|
+
EditArea.prototype.comment_or_quote= function(){
|
29
|
+
var new_class="", close_tag="", sy, arg, i;
|
30
|
+
sy = parent.editAreaLoader.syntax[editArea.current_code_lang];
|
31
|
+
arg = EditArea.prototype.comment_or_quote.arguments[0];
|
32
|
+
|
33
|
+
for( i in sy["quotes"] ){
|
34
|
+
if(arg.indexOf(i)==0){
|
35
|
+
new_class="quotesmarks";
|
36
|
+
close_tag=sy["quotes"][i];
|
37
|
+
}
|
38
|
+
}
|
39
|
+
if(new_class.length==0)
|
40
|
+
{
|
41
|
+
for(var i in sy["comments"]){
|
42
|
+
if( arg.indexOf(i)==0 ){
|
43
|
+
new_class="comments";
|
44
|
+
close_tag=sy["comments"][i];
|
45
|
+
}
|
46
|
+
}
|
47
|
+
}
|
48
|
+
// for single line comment the \n must not be included in the span tags
|
49
|
+
if(close_tag=="\n"){
|
50
|
+
return "µ__"+ new_class +"__µ"+ arg.replace(/(\r?\n)?$/m, "µ_END_µ$1");
|
51
|
+
}else{
|
52
|
+
// the closing tag must be set only if the comment or quotes is closed
|
53
|
+
reg= new RegExp(parent.editAreaLoader.get_escaped_regexp(close_tag)+"$", "m");
|
54
|
+
if( arg.search(reg)!=-1 )
|
55
|
+
return "µ__"+ new_class +"__µ"+ arg +"µ_END_µ";
|
56
|
+
else
|
57
|
+
return "µ__"+ new_class +"__µ"+ arg;
|
58
|
+
}
|
59
|
+
};
|
60
|
+
|
61
|
+
/*
|
62
|
+
// apply special tags arround text to highlight
|
63
|
+
EditArea.prototype.custom_highlight= function(){
|
64
|
+
res= EditArea.prototype.custom_highlight.arguments[1]+"µ__"+ editArea.reg_exp_span_tag +"__µ" + EditArea.prototype.custom_highlight.arguments[2]+"µ_END_µ";
|
65
|
+
if(EditArea.prototype.custom_highlight.arguments.length>5)
|
66
|
+
res+= EditArea.prototype.custom_highlight.arguments[ EditArea.prototype.custom_highlight.arguments.length-3 ];
|
67
|
+
return res;
|
68
|
+
};
|
69
|
+
*/
|
70
|
+
|
71
|
+
// return identication that allow to know if revalidating only the text line won't make the syntax go mad
|
72
|
+
EditArea.prototype.get_syntax_trace= function(text){
|
73
|
+
if(this.settings["syntax"].length>0 && parent.editAreaLoader.syntax[this.settings["syntax"]]["syntax_trace_regexp"])
|
74
|
+
return text.replace(parent.editAreaLoader.syntax[this.settings["syntax"]]["syntax_trace_regexp"], "$3");
|
75
|
+
};
|
76
|
+
|
77
|
+
|
78
|
+
EditArea.prototype.colorize_text= function(text){
|
79
|
+
//text="<div id='result' class='area' style='position: relative; z-index: 4; height: 500px; overflow: scroll;border: solid black 1px;'> ";
|
80
|
+
/*
|
81
|
+
if(this.isOpera){
|
82
|
+
// opera can't use pre element tabulation cause a tab=6 chars in the textarea and 8 chars in the pre
|
83
|
+
text= this.replace_tab(text);
|
84
|
+
}*/
|
85
|
+
|
86
|
+
text= " "+text; // for easier regExp
|
87
|
+
|
88
|
+
/*if(this.do_html_tags)
|
89
|
+
text= text.replace(/(<[a-z]+ [^>]*>)/gi, '[__htmlTag__]$1[_END_]');*/
|
90
|
+
if(this.settings["syntax"].length>0)
|
91
|
+
text= this.apply_syntax(text, this.settings["syntax"]);
|
92
|
+
|
93
|
+
// remove the first space added
|
94
|
+
return text.substr(1).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/µ_END_µ/g,"</span>").replace(/µ__([a-zA-Z0-9]+)__µ/g,"<span class='$1'>");
|
95
|
+
};
|
96
|
+
|
97
|
+
EditArea.prototype.apply_syntax= function(text, lang){
|
98
|
+
var sy;
|
99
|
+
this.current_code_lang=lang;
|
100
|
+
|
101
|
+
if(!parent.editAreaLoader.syntax[lang])
|
102
|
+
return text;
|
103
|
+
|
104
|
+
sy = parent.editAreaLoader.syntax[lang];
|
105
|
+
if(sy["custom_regexp"]['before']){
|
106
|
+
for( var i in sy["custom_regexp"]['before']){
|
107
|
+
var convert="$1µ__"+ sy["custom_regexp"]['before'][i]['class'] +"__µ$2µ_END_µ$3";
|
108
|
+
text= text.replace(sy["custom_regexp"]['before'][i]['regexp'], convert);
|
109
|
+
}
|
110
|
+
}
|
111
|
+
|
112
|
+
if(sy["comment_or_quote_reg_exp"]){
|
113
|
+
//setTimeout("_$('debug_area').value=editArea.comment_or_quote_reg_exp;", 500);
|
114
|
+
text= text.replace(sy["comment_or_quote_reg_exp"], this.comment_or_quote);
|
115
|
+
}
|
116
|
+
|
117
|
+
if(sy["keywords_reg_exp"]){
|
118
|
+
for(var i in sy["keywords_reg_exp"]){
|
119
|
+
text= text.replace(sy["keywords_reg_exp"][i], 'µ__'+i+'__µ$2µ_END_µ');
|
120
|
+
}
|
121
|
+
}
|
122
|
+
|
123
|
+
if(sy["delimiters_reg_exp"]){
|
124
|
+
text= text.replace(sy["delimiters_reg_exp"], 'µ__delimiters__µ$1µ_END_µ');
|
125
|
+
}
|
126
|
+
|
127
|
+
if(sy["operators_reg_exp"]){
|
128
|
+
text= text.replace(sy["operators_reg_exp"], 'µ__operators__µ$1µ_END_µ');
|
129
|
+
}
|
130
|
+
|
131
|
+
if(sy["custom_regexp"]['after']){
|
132
|
+
for( var i in sy["custom_regexp"]['after']){
|
133
|
+
var convert="$1µ__"+ sy["custom_regexp"]['after'][i]['class'] +"__µ$2µ_END_µ$3";
|
134
|
+
text= text.replace(sy["custom_regexp"]['after'][i]['regexp'], convert);
|
135
|
+
}
|
136
|
+
}
|
137
|
+
|
138
|
+
return text;
|
139
|
+
};
|
@@ -0,0 +1,73 @@
|
|
1
|
+
|
2
|
+
EditAreaLoader.prototype.start_resize_area= function(){
|
3
|
+
var d=document,a,div,width,height,father;
|
4
|
+
|
5
|
+
d.onmouseup= editAreaLoader.end_resize_area;
|
6
|
+
d.onmousemove= editAreaLoader.resize_area;
|
7
|
+
editAreaLoader.toggle(editAreaLoader.resize["id"]);
|
8
|
+
|
9
|
+
a = editAreas[editAreaLoader.resize["id"]]["textarea"];
|
10
|
+
div = d.getElementById("edit_area_resize");
|
11
|
+
if(!div){
|
12
|
+
div= d.createElement("div");
|
13
|
+
div.id="edit_area_resize";
|
14
|
+
div.style.border="dashed #888888 1px";
|
15
|
+
}
|
16
|
+
width = a.offsetWidth -2;
|
17
|
+
height = a.offsetHeight -2;
|
18
|
+
|
19
|
+
div.style.display = "block";
|
20
|
+
div.style.width = width+"px";
|
21
|
+
div.style.height = height+"px";
|
22
|
+
father= a.parentNode;
|
23
|
+
father.insertBefore(div, a);
|
24
|
+
|
25
|
+
a.style.display="none";
|
26
|
+
|
27
|
+
editAreaLoader.resize["start_top"]= calculeOffsetTop(div);
|
28
|
+
editAreaLoader.resize["start_left"]= calculeOffsetLeft(div);
|
29
|
+
};
|
30
|
+
|
31
|
+
EditAreaLoader.prototype.end_resize_area= function(e){
|
32
|
+
var d=document,div,a,width,height;
|
33
|
+
|
34
|
+
d.onmouseup="";
|
35
|
+
d.onmousemove="";
|
36
|
+
|
37
|
+
div = d.getElementById("edit_area_resize");
|
38
|
+
a= editAreas[editAreaLoader.resize["id"]]["textarea"];
|
39
|
+
width = Math.max(editAreas[editAreaLoader.resize["id"]]["settings"]["min_width"], div.offsetWidth-4);
|
40
|
+
height = Math.max(editAreas[editAreaLoader.resize["id"]]["settings"]["min_height"], div.offsetHeight-4);
|
41
|
+
if(editAreaLoader.isIE==6){
|
42
|
+
width-=2;
|
43
|
+
height-=2;
|
44
|
+
}
|
45
|
+
a.style.width = width+"px";
|
46
|
+
a.style.height = height+"px";
|
47
|
+
div.style.display = "none";
|
48
|
+
a.style.display = "inline";
|
49
|
+
a.selectionStart = editAreaLoader.resize["selectionStart"];
|
50
|
+
a.selectionEnd = editAreaLoader.resize["selectionEnd"];
|
51
|
+
editAreaLoader.toggle(editAreaLoader.resize["id"]);
|
52
|
+
|
53
|
+
return false;
|
54
|
+
};
|
55
|
+
|
56
|
+
EditAreaLoader.prototype.resize_area= function(e){
|
57
|
+
var allow,newHeight,newWidth;
|
58
|
+
allow = editAreas[editAreaLoader.resize["id"]]["settings"]["allow_resize"];
|
59
|
+
if(allow=="both" || allow=="y")
|
60
|
+
{
|
61
|
+
newHeight = Math.max(20, getMouseY(e)- editAreaLoader.resize["start_top"]);
|
62
|
+
document.getElementById("edit_area_resize").style.height= newHeight+"px";
|
63
|
+
}
|
64
|
+
if(allow=="both" || allow=="x")
|
65
|
+
{
|
66
|
+
newWidth= Math.max(20, getMouseX(e)- editAreaLoader.resize["start_left"]);
|
67
|
+
document.getElementById("edit_area_resize").style.width= newWidth+"px";
|
68
|
+
}
|
69
|
+
|
70
|
+
return false;
|
71
|
+
};
|
72
|
+
|
73
|
+
editAreaLoader.waiting_loading["resize_area.js"]= "loaded";
|
@@ -0,0 +1,174 @@
|
|
1
|
+
EditArea.prototype.show_search = function(){
|
2
|
+
if(_$("area_search_replace").style.visibility=="visible"){
|
3
|
+
this.hidden_search();
|
4
|
+
}else{
|
5
|
+
this.open_inline_popup("area_search_replace");
|
6
|
+
var text= this.area_get_selection();
|
7
|
+
var search= text.split("\n")[0];
|
8
|
+
_$("area_search").value= search;
|
9
|
+
_$("area_search").focus();
|
10
|
+
}
|
11
|
+
};
|
12
|
+
|
13
|
+
EditArea.prototype.hidden_search= function(){
|
14
|
+
/*_$("area_search_replace").style.visibility="hidden";
|
15
|
+
this.textarea.focus();
|
16
|
+
var icon= _$("search");
|
17
|
+
setAttribute(icon, "class", getAttribute(icon, "class").replace(/ selected/g, "") );*/
|
18
|
+
this.close_inline_popup("area_search_replace");
|
19
|
+
};
|
20
|
+
|
21
|
+
EditArea.prototype.area_search= function(mode){
|
22
|
+
|
23
|
+
if(!mode)
|
24
|
+
mode="search";
|
25
|
+
_$("area_search_msg").innerHTML="";
|
26
|
+
var search=_$("area_search").value;
|
27
|
+
|
28
|
+
this.textarea.focus();
|
29
|
+
this.textarea.textareaFocused=true;
|
30
|
+
|
31
|
+
var infos= this.get_selection_infos();
|
32
|
+
var start= infos["selectionStart"];
|
33
|
+
var pos=-1;
|
34
|
+
var pos_begin=-1;
|
35
|
+
var length=search.length;
|
36
|
+
|
37
|
+
if(_$("area_search_replace").style.visibility!="visible"){
|
38
|
+
this.show_search();
|
39
|
+
return;
|
40
|
+
}
|
41
|
+
if(search.length==0){
|
42
|
+
_$("area_search_msg").innerHTML=this.get_translation("search_field_empty");
|
43
|
+
return;
|
44
|
+
}
|
45
|
+
// advance to the next occurence if no text selected
|
46
|
+
if(mode!="replace" ){
|
47
|
+
if(_$("area_search_reg_exp").checked)
|
48
|
+
start++;
|
49
|
+
else
|
50
|
+
start+= search.length;
|
51
|
+
}
|
52
|
+
|
53
|
+
//search
|
54
|
+
if(_$("area_search_reg_exp").checked){
|
55
|
+
// regexp search
|
56
|
+
var opt="m";
|
57
|
+
if(!_$("area_search_match_case").checked)
|
58
|
+
opt+="i";
|
59
|
+
var reg= new RegExp(search, opt);
|
60
|
+
pos= infos["full_text"].substr(start).search(reg);
|
61
|
+
pos_begin= infos["full_text"].search(reg);
|
62
|
+
if(pos!=-1){
|
63
|
+
pos+=start;
|
64
|
+
length=infos["full_text"].substr(start).match(reg)[0].length;
|
65
|
+
}else if(pos_begin!=-1){
|
66
|
+
length=infos["full_text"].match(reg)[0].length;
|
67
|
+
}
|
68
|
+
}else{
|
69
|
+
if(_$("area_search_match_case").checked){
|
70
|
+
pos= infos["full_text"].indexOf(search, start);
|
71
|
+
pos_begin= infos["full_text"].indexOf(search);
|
72
|
+
}else{
|
73
|
+
pos= infos["full_text"].toLowerCase().indexOf(search.toLowerCase(), start);
|
74
|
+
pos_begin= infos["full_text"].toLowerCase().indexOf(search.toLowerCase());
|
75
|
+
}
|
76
|
+
}
|
77
|
+
|
78
|
+
// interpret result
|
79
|
+
if(pos==-1 && pos_begin==-1){
|
80
|
+
_$("area_search_msg").innerHTML="<strong>"+search+"</strong> "+this.get_translation("not_found");
|
81
|
+
return;
|
82
|
+
}else if(pos==-1 && pos_begin != -1){
|
83
|
+
begin= pos_begin;
|
84
|
+
_$("area_search_msg").innerHTML=this.get_translation("restart_search_at_begin");
|
85
|
+
}else
|
86
|
+
begin= pos;
|
87
|
+
|
88
|
+
//_$("area_search_msg").innerHTML+="<strong>"+search+"</strong> found at "+begin+" strat at "+start+" pos "+pos+" curs"+ infos["indexOfCursor"]+".";
|
89
|
+
if(mode=="replace" && pos==infos["indexOfCursor"]){
|
90
|
+
var replace= _$("area_replace").value;
|
91
|
+
var new_text="";
|
92
|
+
if(_$("area_search_reg_exp").checked){
|
93
|
+
var opt="m";
|
94
|
+
if(!_$("area_search_match_case").checked)
|
95
|
+
opt+="i";
|
96
|
+
var reg= new RegExp(search, opt);
|
97
|
+
new_text= infos["full_text"].substr(0, begin) + infos["full_text"].substr(start).replace(reg, replace);
|
98
|
+
}else{
|
99
|
+
new_text= infos["full_text"].substr(0, begin) + replace + infos["full_text"].substr(begin + length);
|
100
|
+
}
|
101
|
+
this.textarea.value=new_text;
|
102
|
+
this.area_select(begin, length);
|
103
|
+
this.area_search();
|
104
|
+
}else
|
105
|
+
this.area_select(begin, length);
|
106
|
+
};
|
107
|
+
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
EditArea.prototype.area_replace= function(){
|
112
|
+
this.area_search("replace");
|
113
|
+
};
|
114
|
+
|
115
|
+
EditArea.prototype.area_replace_all= function(){
|
116
|
+
/* this.area_select(0, 0);
|
117
|
+
_$("area_search_msg").innerHTML="";
|
118
|
+
while(_$("area_search_msg").innerHTML==""){
|
119
|
+
this.area_replace();
|
120
|
+
}*/
|
121
|
+
|
122
|
+
var base_text= this.textarea.value;
|
123
|
+
var search= _$("area_search").value;
|
124
|
+
var replace= _$("area_replace").value;
|
125
|
+
if(search.length==0){
|
126
|
+
_$("area_search_msg").innerHTML=this.get_translation("search_field_empty");
|
127
|
+
return ;
|
128
|
+
}
|
129
|
+
|
130
|
+
var new_text="";
|
131
|
+
var nb_change=0;
|
132
|
+
if(_$("area_search_reg_exp").checked){
|
133
|
+
// regExp
|
134
|
+
var opt="mg";
|
135
|
+
if(!_$("area_search_match_case").checked)
|
136
|
+
opt+="i";
|
137
|
+
var reg= new RegExp(search, opt);
|
138
|
+
nb_change= infos["full_text"].match(reg).length;
|
139
|
+
new_text= infos["full_text"].replace(reg, replace);
|
140
|
+
|
141
|
+
}else{
|
142
|
+
|
143
|
+
if(_$("area_search_match_case").checked){
|
144
|
+
var tmp_tab=base_text.split(search);
|
145
|
+
nb_change= tmp_tab.length -1 ;
|
146
|
+
new_text= tmp_tab.join(replace);
|
147
|
+
}else{
|
148
|
+
// case insensitive
|
149
|
+
var lower_value=base_text.toLowerCase();
|
150
|
+
var lower_search=search.toLowerCase();
|
151
|
+
|
152
|
+
var start=0;
|
153
|
+
var pos= lower_value.indexOf(lower_search);
|
154
|
+
while(pos!=-1){
|
155
|
+
nb_change++;
|
156
|
+
new_text+= this.textarea.value.substring(start , pos)+replace;
|
157
|
+
start=pos+ search.length;
|
158
|
+
pos= lower_value.indexOf(lower_search, pos+1);
|
159
|
+
}
|
160
|
+
new_text+= this.textarea.value.substring(start);
|
161
|
+
}
|
162
|
+
}
|
163
|
+
if(new_text==base_text){
|
164
|
+
_$("area_search_msg").innerHTML="<strong>"+search+"</strong> "+this.get_translation("not_found");
|
165
|
+
}else{
|
166
|
+
this.textarea.value= new_text;
|
167
|
+
_$("area_search_msg").innerHTML="<strong>"+nb_change+"</strong> "+this.get_translation("occurrence_replaced");
|
168
|
+
// firefox and opera doesn't manage with the focus if it's done directly
|
169
|
+
//editArea.textarea.focus();editArea.textarea.textareaFocused=true;
|
170
|
+
setTimeout("editArea.textarea.focus();editArea.textarea.textareaFocused=true;", 100);
|
171
|
+
}
|
172
|
+
|
173
|
+
|
174
|
+
};
|
@@ -0,0 +1,530 @@
|
|
1
|
+
body, html{
|
2
|
+
margin: 0;
|
3
|
+
padding: 0;
|
4
|
+
height: 100%;
|
5
|
+
border: none;
|
6
|
+
overflow: hidden;
|
7
|
+
background-color: #FFF;
|
8
|
+
}
|
9
|
+
|
10
|
+
body, html, table, form, textarea{
|
11
|
+
font: 12px monospace, sans-serif;
|
12
|
+
}
|
13
|
+
|
14
|
+
#editor{
|
15
|
+
border: solid #888 1px;
|
16
|
+
overflow: hidden;
|
17
|
+
}
|
18
|
+
|
19
|
+
#result{
|
20
|
+
z-index: 4;
|
21
|
+
overflow-x: auto;
|
22
|
+
overflow-y: scroll;
|
23
|
+
border-top: solid #888 1px;
|
24
|
+
border-bottom: solid #888 1px;
|
25
|
+
position: relative;
|
26
|
+
clear: both;
|
27
|
+
}
|
28
|
+
|
29
|
+
#result.empty{
|
30
|
+
overflow: hidden;
|
31
|
+
}
|
32
|
+
|
33
|
+
#container{
|
34
|
+
overflow: hidden;
|
35
|
+
border: solid blue 0;
|
36
|
+
position: relative;
|
37
|
+
z-index: 10;
|
38
|
+
padding: 0 5px 0 45px;
|
39
|
+
/*padding-right: 5px;*/
|
40
|
+
}
|
41
|
+
|
42
|
+
#textarea{
|
43
|
+
position: relative;
|
44
|
+
top: 0;
|
45
|
+
left: 0;
|
46
|
+
margin: 0;
|
47
|
+
padding: 0;
|
48
|
+
width: 100%;
|
49
|
+
height: 100%;
|
50
|
+
overflow: hidden;
|
51
|
+
z-index: 7;
|
52
|
+
border-width: 0;
|
53
|
+
background-color: transparent;
|
54
|
+
resize: none;
|
55
|
+
}
|
56
|
+
|
57
|
+
#textarea, #textarea:hover{
|
58
|
+
outline: none; /* safari outline fix */
|
59
|
+
}
|
60
|
+
|
61
|
+
#content_highlight{
|
62
|
+
white-space: pre;
|
63
|
+
margin: 0;
|
64
|
+
padding: 0;
|
65
|
+
position : absolute;
|
66
|
+
z-index: 4;
|
67
|
+
overflow: visible;
|
68
|
+
}
|
69
|
+
|
70
|
+
|
71
|
+
#selection_field, #selection_field_text{
|
72
|
+
margin: 0;
|
73
|
+
background-color: #E1F2F9;
|
74
|
+
/* height: 1px; */
|
75
|
+
position: absolute;
|
76
|
+
z-index: 5;
|
77
|
+
top: -100px;
|
78
|
+
padding: 0;
|
79
|
+
white-space: pre;
|
80
|
+
overflow: hidden;
|
81
|
+
}
|
82
|
+
|
83
|
+
#selection_field.show_colors {
|
84
|
+
z-index: 3;
|
85
|
+
background-color:#EDF9FC;
|
86
|
+
|
87
|
+
}
|
88
|
+
|
89
|
+
#selection_field strong{
|
90
|
+
font-weight:normal;
|
91
|
+
}
|
92
|
+
|
93
|
+
#selection_field.show_colors *, #selection_field_text * {
|
94
|
+
visibility: hidden;
|
95
|
+
}
|
96
|
+
|
97
|
+
#selection_field_text{
|
98
|
+
background-color:transparent;
|
99
|
+
}
|
100
|
+
|
101
|
+
#selection_field_text strong{
|
102
|
+
font-weight:normal;
|
103
|
+
background-color:#3399FE;
|
104
|
+
color: #FFF;
|
105
|
+
visibility:visible;
|
106
|
+
}
|
107
|
+
|
108
|
+
#container.word_wrap #content_highlight,
|
109
|
+
#container.word_wrap #selection_field,
|
110
|
+
#container.word_wrap #selection_field_text,
|
111
|
+
#container.word_wrap #test_font_size{
|
112
|
+
white-space: pre-wrap; /* css-3 */
|
113
|
+
white-space: -moz-pre-wrap !important; /* Mozilla, since 1999 */
|
114
|
+
white-space: -pre-wrap; /* Opera 4-6 */
|
115
|
+
white-space: -o-pre-wrap; /* Opera 7 */
|
116
|
+
word-wrap: break-word; /* Internet Explorer 5.5+ */
|
117
|
+
width: 99%;
|
118
|
+
}
|
119
|
+
|
120
|
+
#line_number{
|
121
|
+
position: absolute;
|
122
|
+
overflow: hidden;
|
123
|
+
border-right: solid black 1px;
|
124
|
+
z-index:8;
|
125
|
+
width: 38px;
|
126
|
+
padding: 0 5px 0 0;
|
127
|
+
margin: 0 0 0 -45px;
|
128
|
+
text-align: right;
|
129
|
+
color: #AAAAAA;
|
130
|
+
}
|
131
|
+
|
132
|
+
#test_font_size{
|
133
|
+
padding: 0;
|
134
|
+
margin: 0;
|
135
|
+
visibility: hidden;
|
136
|
+
position: absolute;
|
137
|
+
white-space: pre;
|
138
|
+
}
|
139
|
+
|
140
|
+
pre{
|
141
|
+
margin: 0;
|
142
|
+
padding: 0;
|
143
|
+
}
|
144
|
+
|
145
|
+
.hidden{
|
146
|
+
opacity: 0.2;
|
147
|
+
filter:alpha(opacity=20);
|
148
|
+
}
|
149
|
+
|
150
|
+
#result .edit_area_cursor{
|
151
|
+
position: absolute;
|
152
|
+
z-index:6;
|
153
|
+
background-color: #FF6633;
|
154
|
+
top: -100px;
|
155
|
+
margin: 0;
|
156
|
+
}
|
157
|
+
|
158
|
+
#result .edit_area_selection_field .overline{
|
159
|
+
background-color: #996600;
|
160
|
+
}
|
161
|
+
|
162
|
+
|
163
|
+
/* area popup */
|
164
|
+
.editarea_popup{
|
165
|
+
border: solid 1px #888888;
|
166
|
+
background-color: #ECE9D8;
|
167
|
+
width: 250px;
|
168
|
+
padding: 4px;
|
169
|
+
position: absolute;
|
170
|
+
visibility: hidden;
|
171
|
+
z-index: 15;
|
172
|
+
top: -500px;
|
173
|
+
}
|
174
|
+
|
175
|
+
.editarea_popup, .editarea_popup table{
|
176
|
+
font-family: sans-serif;
|
177
|
+
font-size: 10pt;
|
178
|
+
}
|
179
|
+
|
180
|
+
.editarea_popup img{
|
181
|
+
border: 0;
|
182
|
+
}
|
183
|
+
|
184
|
+
.editarea_popup .close_popup{
|
185
|
+
float: right;
|
186
|
+
line-height: 16px;
|
187
|
+
border: 0;
|
188
|
+
padding: 0;
|
189
|
+
}
|
190
|
+
|
191
|
+
.editarea_popup h1,.editarea_popup h2,.editarea_popup h3,.editarea_popup h4,.editarea_popup h5,.editarea_popup h6{
|
192
|
+
margin: 0;
|
193
|
+
padding: 0;
|
194
|
+
}
|
195
|
+
|
196
|
+
.editarea_popup .copyright{
|
197
|
+
text-align: right;
|
198
|
+
}
|
199
|
+
|
200
|
+
/* Area_search */
|
201
|
+
div#area_search_replace{
|
202
|
+
/*width: 250px;*/
|
203
|
+
}
|
204
|
+
|
205
|
+
div#area_search_replace img{
|
206
|
+
border: 0;
|
207
|
+
}
|
208
|
+
|
209
|
+
div#area_search_replace div.button{
|
210
|
+
text-align: center;
|
211
|
+
line-height: 1.7em;
|
212
|
+
}
|
213
|
+
|
214
|
+
div#area_search_replace .button a{
|
215
|
+
cursor: pointer;
|
216
|
+
border: solid 1px #888888;
|
217
|
+
background-color: #DEDEDE;
|
218
|
+
text-decoration: none;
|
219
|
+
padding: 0 2px;
|
220
|
+
color: #000000;
|
221
|
+
white-space: nowrap;
|
222
|
+
}
|
223
|
+
|
224
|
+
div#area_search_replace a:hover{
|
225
|
+
/*border: solid 1px #888888;*/
|
226
|
+
background-color: #EDEDED;
|
227
|
+
}
|
228
|
+
|
229
|
+
div#area_search_replace #move_area_search_replace{
|
230
|
+
cursor: move;
|
231
|
+
border: solid 1px #888;
|
232
|
+
}
|
233
|
+
|
234
|
+
div#area_search_replace #close_area_search_replace{
|
235
|
+
text-align: right;
|
236
|
+
vertical-align: top;
|
237
|
+
white-space: nowrap;
|
238
|
+
}
|
239
|
+
|
240
|
+
div#area_search_replace #area_search_msg{
|
241
|
+
height: 18px;
|
242
|
+
overflow: hidden;
|
243
|
+
border-top: solid 1px #888;
|
244
|
+
margin-top: 3px;
|
245
|
+
}
|
246
|
+
|
247
|
+
/* area help */
|
248
|
+
#edit_area_help{
|
249
|
+
width: 350px;
|
250
|
+
}
|
251
|
+
|
252
|
+
#edit_area_help div.close_popup{
|
253
|
+
float: right;
|
254
|
+
}
|
255
|
+
|
256
|
+
/* area_toolbar */
|
257
|
+
.area_toolbar{
|
258
|
+
/*font: 11px sans-serif;*/
|
259
|
+
width: 100%;
|
260
|
+
/*height: 21px; */
|
261
|
+
margin: 0;
|
262
|
+
padding: 0;
|
263
|
+
background-color: #ECE9D8;
|
264
|
+
text-align: center;
|
265
|
+
}
|
266
|
+
|
267
|
+
.area_toolbar, .area_toolbar table{
|
268
|
+
font: 11px sans-serif;
|
269
|
+
}
|
270
|
+
|
271
|
+
.area_toolbar img{
|
272
|
+
border: 0;
|
273
|
+
vertical-align: middle;
|
274
|
+
}
|
275
|
+
|
276
|
+
.area_toolbar input{
|
277
|
+
margin: 0;
|
278
|
+
padding: 0;
|
279
|
+
}
|
280
|
+
|
281
|
+
.area_toolbar select{
|
282
|
+
font-family: 'MS Sans Serif',sans-serif,Verdana,Arial;
|
283
|
+
font-size: 7pt;
|
284
|
+
font-weight: normal;
|
285
|
+
margin: 2px 0 0 0 ;
|
286
|
+
padding: 0;
|
287
|
+
vertical-align: top;
|
288
|
+
background-color: #F0F0EE;
|
289
|
+
}
|
290
|
+
|
291
|
+
table.statusbar{
|
292
|
+
width: 100%;
|
293
|
+
}
|
294
|
+
|
295
|
+
.area_toolbar td.infos{
|
296
|
+
text-align: center;
|
297
|
+
width: 130px;
|
298
|
+
border-right: solid 1px #888;
|
299
|
+
border-width: 0 1px 0 0;
|
300
|
+
padding: 0;
|
301
|
+
}
|
302
|
+
|
303
|
+
.area_toolbar td.total{
|
304
|
+
text-align: right;
|
305
|
+
width: 50px;
|
306
|
+
padding: 0;
|
307
|
+
}
|
308
|
+
|
309
|
+
.area_toolbar td.resize{
|
310
|
+
text-align: right;
|
311
|
+
}
|
312
|
+
/*
|
313
|
+
.area_toolbar span{
|
314
|
+
line-height: 1px;
|
315
|
+
padding: 0;
|
316
|
+
margin: 0;
|
317
|
+
}*/
|
318
|
+
|
319
|
+
.area_toolbar span#resize_area{
|
320
|
+
cursor: nw-resize;
|
321
|
+
visibility: hidden;
|
322
|
+
}
|
323
|
+
|
324
|
+
/* toolbar buttons */
|
325
|
+
.editAreaButtonNormal, .editAreaButtonOver, .editAreaButtonDown, .editAreaSeparator, .editAreaSeparatorLine, .editAreaButtonDisabled, .editAreaButtonSelected {
|
326
|
+
border: 0; margin: 0; padding: 0; background: transparent;
|
327
|
+
margin-top: 0;
|
328
|
+
margin-left: 1px;
|
329
|
+
padding: 0;
|
330
|
+
}
|
331
|
+
|
332
|
+
.editAreaButtonNormal {
|
333
|
+
border: 1px solid #ECE9D8 !important;
|
334
|
+
cursor: pointer;
|
335
|
+
}
|
336
|
+
|
337
|
+
.editAreaButtonOver {
|
338
|
+
border: 1px solid #0A246A !important;
|
339
|
+
cursor: pointer;
|
340
|
+
background-color: #B6BDD2;
|
341
|
+
}
|
342
|
+
|
343
|
+
.editAreaButtonDown {
|
344
|
+
cursor: pointer;
|
345
|
+
border: 1px solid #0A246A !important;
|
346
|
+
background-color: #8592B5;
|
347
|
+
}
|
348
|
+
|
349
|
+
.editAreaButtonSelected {
|
350
|
+
border: 1px solid #C0C0BB !important;
|
351
|
+
cursor: pointer;
|
352
|
+
background-color: #F4F2E8;
|
353
|
+
}
|
354
|
+
|
355
|
+
.editAreaButtonDisabled {
|
356
|
+
filter:progid:DXImageTransform.Microsoft.Alpha(opacity=30);
|
357
|
+
-moz-opacity:0.3;
|
358
|
+
opacity: 0.3;
|
359
|
+
border: 1px solid #F0F0EE !important;
|
360
|
+
cursor: pointer;
|
361
|
+
}
|
362
|
+
|
363
|
+
.editAreaSeparatorLine {
|
364
|
+
margin: 1px 2px;
|
365
|
+
background-color: #C0C0BB;
|
366
|
+
width: 2px;
|
367
|
+
height: 18px;
|
368
|
+
}
|
369
|
+
|
370
|
+
/* waiting screen */
|
371
|
+
#processing{
|
372
|
+
display: none;
|
373
|
+
background-color:#ECE9D8;
|
374
|
+
border: solid #888 1px;
|
375
|
+
position: absolute;
|
376
|
+
top: 0;
|
377
|
+
left: 0;
|
378
|
+
width: 100%;
|
379
|
+
height: 100%;
|
380
|
+
z-index: 100;
|
381
|
+
text-align: center;
|
382
|
+
}
|
383
|
+
|
384
|
+
#processing_text{
|
385
|
+
position:absolute;
|
386
|
+
left: 50%;
|
387
|
+
top: 50%;
|
388
|
+
width: 200px;
|
389
|
+
height: 20px;
|
390
|
+
margin-left: -100px;
|
391
|
+
margin-top: -10px;
|
392
|
+
text-align: center;
|
393
|
+
}
|
394
|
+
/* end */
|
395
|
+
|
396
|
+
|
397
|
+
/**** tab browsing area ****/
|
398
|
+
#tab_browsing_area{
|
399
|
+
display: none;
|
400
|
+
background-color: #CCC9A8;
|
401
|
+
border-top: 1px solid #888;
|
402
|
+
text-align: left;
|
403
|
+
margin: 0;
|
404
|
+
}
|
405
|
+
|
406
|
+
#tab_browsing_list {
|
407
|
+
padding: 0;
|
408
|
+
margin: 0;
|
409
|
+
list-style-type: none;
|
410
|
+
white-space: nowrap;
|
411
|
+
}
|
412
|
+
#tab_browsing_list li {
|
413
|
+
float: left;
|
414
|
+
margin: -1px;
|
415
|
+
}
|
416
|
+
#tab_browsing_list a {
|
417
|
+
position: relative;
|
418
|
+
display: block;
|
419
|
+
text-decoration: none;
|
420
|
+
float: left;
|
421
|
+
cursor: pointer;
|
422
|
+
line-height:14px;
|
423
|
+
}
|
424
|
+
|
425
|
+
#tab_browsing_list a span {
|
426
|
+
display: block;
|
427
|
+
color: #000;
|
428
|
+
background: #ECE9D8;
|
429
|
+
border: 1px solid #888;
|
430
|
+
border-width: 1px 1px 0;
|
431
|
+
text-align: center;
|
432
|
+
padding: 2px 2px 1px 4px;
|
433
|
+
position: relative; /*IE 6 hack */
|
434
|
+
}
|
435
|
+
|
436
|
+
#tab_browsing_list a b {
|
437
|
+
display: block;
|
438
|
+
border-bottom: 2px solid #617994;
|
439
|
+
}
|
440
|
+
|
441
|
+
#tab_browsing_list a .edited {
|
442
|
+
display: none;
|
443
|
+
}
|
444
|
+
|
445
|
+
#tab_browsing_list a.edited .edited {
|
446
|
+
display: inline;
|
447
|
+
}
|
448
|
+
|
449
|
+
#tab_browsing_list a img{
|
450
|
+
margin-left: 7px;
|
451
|
+
}
|
452
|
+
|
453
|
+
#tab_browsing_list a.edited img{
|
454
|
+
margin-left: 3px;
|
455
|
+
}
|
456
|
+
|
457
|
+
#tab_browsing_list a:hover span {
|
458
|
+
background: #F4F2E8;
|
459
|
+
border-color: #0A246A;
|
460
|
+
}
|
461
|
+
|
462
|
+
#tab_browsing_list .selected a span{
|
463
|
+
background: #046380;
|
464
|
+
color: #FFF;
|
465
|
+
}
|
466
|
+
|
467
|
+
|
468
|
+
#no_file_selected{
|
469
|
+
height: 100%;
|
470
|
+
width: 150%; /* Opera need more than 100% */
|
471
|
+
background: #CCC;
|
472
|
+
display: none;
|
473
|
+
z-index: 20;
|
474
|
+
position: absolute;
|
475
|
+
}
|
476
|
+
|
477
|
+
|
478
|
+
/*** Non-editable mode ***/
|
479
|
+
.non_editable #editor
|
480
|
+
{
|
481
|
+
border-width: 0 1px;
|
482
|
+
}
|
483
|
+
|
484
|
+
.non_editable .area_toolbar
|
485
|
+
{
|
486
|
+
display: none;
|
487
|
+
}
|
488
|
+
|
489
|
+
/*** Auto completion ***/
|
490
|
+
#auto_completion_area
|
491
|
+
{
|
492
|
+
background: #FFF;
|
493
|
+
border: solid 1px #888;
|
494
|
+
position: absolute;
|
495
|
+
z-index: 15;
|
496
|
+
width: 280px;
|
497
|
+
height: 180px;
|
498
|
+
overflow: auto;
|
499
|
+
display:none;
|
500
|
+
}
|
501
|
+
|
502
|
+
#auto_completion_area a, #auto_completion_area a:visited
|
503
|
+
{
|
504
|
+
display: block;
|
505
|
+
padding: 0 2px 1px;
|
506
|
+
color: #000;
|
507
|
+
text-decoration:none;
|
508
|
+
}
|
509
|
+
|
510
|
+
#auto_completion_area a:hover, #auto_completion_area a:focus, #auto_completion_area a.focus
|
511
|
+
{
|
512
|
+
background: #D6E1FE;
|
513
|
+
text-decoration:none;
|
514
|
+
}
|
515
|
+
|
516
|
+
#auto_completion_area ul
|
517
|
+
{
|
518
|
+
margin: 0;
|
519
|
+
padding: 0;
|
520
|
+
list-style: none inside;
|
521
|
+
}
|
522
|
+
#auto_completion_area li
|
523
|
+
{
|
524
|
+
padding: 0;
|
525
|
+
}
|
526
|
+
#auto_completion_area .prefix
|
527
|
+
{
|
528
|
+
font-style: italic;
|
529
|
+
padding: 0 3px;
|
530
|
+
}
|