comparison wiki/htdocs/applets/FCKeditor/editor/css/behaviors/showtableborders.htc @ 0:77665d8e2254

tag of nonpublic@localhost--archive/moin--enterprise--1.5--base-0 (automatically generated log message) imported from: moin--main--1.5--base-0
author Thomas Waldmann <tw-public@gmx.de>
date Thu, 22 Sep 2005 15:09:50 +0000
parents
children 645324d706e2 07862b0663fd
comparison
equal deleted inserted replaced
-1:000000000000 0:77665d8e2254
1 <public:component lightweight="true">
2
3 <public:attach event="oncontentready" onevent="ShowBorders()" />
4 <public:attach event="onpropertychange" onevent="OnPropertyChange()" />
5
6 <script language="javascript">
7 var oClassRegex = /\s*FCK__ShowTableBorders/ ;
8 var FCKConfig = window.parent.FCKConfig ;
9
10 function ShowBorders()
11 {
12 if ( this.border == 0 )
13 {
14 if ( !oClassRegex.test( this.className ) )
15 this.className += ' FCK__ShowTableBorders' ;
16 }
17 else
18 {
19 if ( oClassRegex.test( this.className ) )
20 {
21 this.className = this.className.replace( oClassRegex, '' ) ;
22 if ( this.className.length == 0 )
23 this.removeAttribute( 'className', 0 ) ;
24 }
25 }
26 }
27
28 function OnPropertyChange()
29 {
30 if ( event.propertyName == 'border' || event.propertyName == 'className' )
31 ShowBorders() ;
32 }
33
34 </script>
35
36 </public:component>