OLD | NEW |
(Empty) | |
| 1 <html> |
| 2 <head> |
| 3 |
| 4 <style> |
| 5 .editing { |
| 6 border: 2px solid red; |
| 7 padding: 12px; |
| 8 font-size: 24px; |
| 9 } |
| 10 </style> |
| 11 <script src=../editing.js language="JavaScript" type="text/JavaScript" ></script
> |
| 12 |
| 13 <script> |
| 14 |
| 15 function editingTest() { |
| 16 moveSelectionForwardByLineCommand(); |
| 17 moveSelectionLeftByCharacterCommand(); |
| 18 } |
| 19 |
| 20 </script> |
| 21 |
| 22 <title>Editing Test</title> |
| 23 </head> |
| 24 <body> |
| 25 <p>This tests to make sure that the caret is visible in the black background by
getting the caret color from the color of the element(span) containing the text,
not the parent element(div) that has the contentEditable attribute. |
| 26 </p> |
| 27 <div contenteditable id="root" class="editing"> |
| 28 <span id="test" style="color: white; background-color: black">Where is my caret?
</span> |
| 29 </div> |
| 30 |
| 31 <script> |
| 32 runEditingTest(); |
| 33 </script> |
| 34 |
| 35 </body> |
| 36 </html> |
| 37 |
| 38 |
OLD | NEW |