Difference between revisions of "Quote Lines"

From TED Notepad
m
Line 1: Line 1:
<noinclude>{{manversion|6.0.0.14}}__NOTOC__</noinclude>
+
<noinclude>{{manversion|6.0.0.16|feature}}__NOTOC__</noinclude>
 
====Quote.. (Alt+Ctrl+Q)====
 
====Quote.. (Alt+Ctrl+Q)====
 
      
 
      
Asks for a {{field|Quote}} phrase to work with and then quotes (i.e. indents) the selection with the specified phrase at the beginning of each {{defined|line}}.
+
Asks for a {{field|Quote Lines|Quote}} phrase to work with and then quotes (i.e. indents) the selection with the specified phrase at the beginning of each {{defined|line}}.
  
Optionally, only {{defined|non-empty lines}} can be quoted, which ensures that {{defined|empty lines}} are not modified at all.
+
Optionally, {{field|Quote Lines|Quote non-empty lines only}} can be used to quote non-empty lines only, which ensures that {{defined|empty lines}} are not modified at all.
  
Optionally, the quoting phrase may be inserted just after all leading {{defined|white-spaces}} on each line. This way, any current line indentation is kept unmodified, and the quoting phrase is appended to that indentation, before the first {{defined|graph}} (i.e. {{defined|non-white-space}}) character.
+
Optionally, using the {{field|Quote Lines|Skip leading spaces}}, the quoting phrase may be inserted just after all leading {{defined|white-spaces}} on each line. This way, any current line indentation is kept unmodified, and the quoting phrase is appended to that indentation, before the first {{defined|graph}} (i.e. {{defined|non-white-space}}) character.
  
Note: When quoting of {{defined|empty lines}} is allowed, and leading {{defined|white-spaces}} are to be skipped, special consequential case occurs. On {{defined|empty lines}}, quoting phrase is simply appended, because leading {{defined|white-spaces}} is all that those line contain.
+
Note: When quoting of {{defined|empty lines}} is allowed, and leading {{defined|white-spaces}} are to be skipped, special consequential case occurs. On {{defined|empty lines}}, quoting phrase is appended, because the skipped leading {{defined|white-spaces}} is all that those line contain.
  
 
Note: The selection always persists in this tool.  
 
Note: The selection always persists in this tool.  
Line 20: Line 20:
 
{{example_end}}
 
{{example_end}}
  
{{example_start}}Result, using {{field|Quote}}: {{string|>_}} and {{field|Quote non-empty lines only}} checked:
+
{{example_start}}Result, using {{field|Quote Lines|Quote}}: {{string|>_}} and {{field|Quote Lines|Quote non-empty lines only}} checked:
 
{{example_body}}<nowiki>----- Original Message -----
 
{{example_body}}<nowiki>----- Original Message -----
> Great notepad!
+
</nowiki>{{example_select|<nowiki>> Great notepad!
  
 
> Tabs, you need tabs for multiple documents. Cosmetic, supeficial,
 
> Tabs, you need tabs for multiple documents. Cosmetic, supeficial,
> of course. But that's what people are looking for these days.</nowiki>
+
> of course. But that's what people are looking for these days.</nowiki>}}
 
{{example_end}}
 
{{example_end}}
  
{{tip}} Combine the {{feature|Quote..}} tool with the {{feature|Close..}} tool in order to write paragraphs or lists in HTML documents without having to bother with {{string|<nowiki><p></nowiki>}} and {{string|<nowiki><li></nowiki>}} tags while writing. Write all paragraphs first, each one on a separate line (you may use {{feature|word wrap}} (hotkey {{hotkey|Ctrl+W}}) to see paragraphs wrapped into several lines, since the {{feature|word wrap}} does not affect tools). When done, select all the lines and use both {{feature|Quote..}} and {{feature|Close..}} tools to add the {{string|<nowiki><p></nowiki>}} and {{string|<nowiki></p></nowiki>}} tags (or {{string|<nowiki><li></nowiki>}} and {{string|<nowiki></li></nowiki>}} tags) to each line.
+
{{tip}} Combine the {{feature|Quote Lines}} tool with the {{feature|Close Lines}} tool in order to write paragraphs or lists in HTML documents without having to bother with {{string|<nowiki><p></nowiki>}} or {{string|<nowiki><li></nowiki>}} tags while writing. Write all paragraphs first, each one on a separate line (you may use {{feature|Word Wrap}} (hotkey {{hotkey|Ctrl+W}}) to see long lines automatically wrapped into several lines, since the {{feature|Word Wrap}} does not affect tools). When done, select all the lines and use both {{feature|Quote Lines}} and {{feature|Close Lines}} tools to add the {{string|<nowiki><p></nowiki>}} and {{string|<nowiki></p></nowiki>}} tags (or {{string|<nowiki><li></nowiki>}} and {{string|<nowiki></li></nowiki>}} tags) to each line.
  
 
{{example_start}}Example:
 
{{example_start}}Example:
Line 38: Line 38:
  
 
{{example_start}}Result, quoting with {{string|<nowiki><li></nowiki>}} and closing with {{string|<nowiki></li></nowiki>}}:
 
{{example_start}}Result, quoting with {{string|<nowiki><li></nowiki>}} and closing with {{string|<nowiki></li></nowiki>}}:
{{example_body}}<nowiki><li>Great notepad!</li>
+
{{example_body}}{{example_select|<nowiki><li>Great notepad!</li>
  
 
<li>Tabs, you need tabs for multiple documents. Cosmetic, supeficial,</li>
 
<li>Tabs, you need tabs for multiple documents. Cosmetic, supeficial,</li>
<li>of course. But that's what people are looking for these days.</li></nowiki>
+
<li>of course. But that's what people are looking for these days.</li></nowiki>}}
 
{{example_end}}
 
{{example_end}}

Revision as of 21:28, 25 April 2011

This section is up to date for TED Notepad version 6.3.1.0.
Control page Control:feature:Quote Lines

Quote.. (Alt+Ctrl+Q)

Asks for a Quote phrase to work with and then quotes (i.e. indents) the selection with the specified phrase at the beginning of each line.

Optionally, Quote non-empty lines only can be used to quote non-empty lines only, which ensures that empty lines are not modified at all.

Optionally, using the Skip leading spaces, the quoting phrase may be inserted just after all leading white-spaces on each line. This way, any current line indentation is kept unmodified, and the quoting phrase is appended to that indentation, before the first graph (i.e. non-white-space) character.

Note: When quoting of empty lines is allowed, and leading white-spaces are to be skipped, special consequential case occurs. On empty lines, quoting phrase is appended, because the skipped leading white-spaces is all that those line contain.

Note: The selection always persists in this tool.

Example: (an e-mail received from a user)
----- Original Message ----- Great notepad! Tabs, you need tabs for multiple documents. Cosmetic, supeficial, of course. But that's what people are looking for these days.
Result, using Quote: >_ and Quote non-empty lines only checked:
----- Original Message ----- > Great notepad! > Tabs, you need tabs for multiple documents. Cosmetic, supeficial, > of course. But that's what people are looking for these days.

Tip: Combine the Quote Lines tool with the Close Lines tool in order to write paragraphs or lists in HTML documents without having to bother with <p> or <li> tags while writing. Write all paragraphs first, each one on a separate line (you may use Word Wrap (hotkey Ctrl+W) to see long lines automatically wrapped into several lines, since the Word Wrap does not affect tools). When done, select all the lines and use both Quote Lines and Close Lines tools to add the <p> and </p> tags (or <li> and </li> tags) to each line.

Example:
Great notepad! Tabs, you need tabs for multiple documents. Cosmetic, supeficial, of course. But that's what people are looking for these days.
Result, quoting with <li> and closing with </li>:
<li>Great notepad!</li> <li>Tabs, you need tabs for multiple documents. Cosmetic, supeficial,</li> <li>of course. But that's what people are looking for these days.</li>