<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to vertically align the right-hand side of comments in program header? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826298#M326395</link>
    <description>&lt;P&gt;I often see others' well-aligned program header comments (e.g., see below), but I still have no idea how the authors made them. Is there a keyboard shortcut that allows us to align comments?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="xyxu_0-1659244472994.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73911iD7D3FF10F8EB043E/image-size/medium?v=v2&amp;amp;px=400" role="button" title="xyxu_0-1659244472994.png" alt="xyxu_0-1659244472994.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sun, 31 Jul 2022 05:15:29 GMT</pubDate>
    <dc:creator>xyxu</dc:creator>
    <dc:date>2022-07-31T05:15:29Z</dc:date>
    <item>
      <title>How to vertically align the right-hand side of comments in program header?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826298#M326395</link>
      <description>&lt;P&gt;I often see others' well-aligned program header comments (e.g., see below), but I still have no idea how the authors made them. Is there a keyboard shortcut that allows us to align comments?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="xyxu_0-1659244472994.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73911iD7D3FF10F8EB043E/image-size/medium?v=v2&amp;amp;px=400" role="button" title="xyxu_0-1659244472994.png" alt="xyxu_0-1659244472994.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 31 Jul 2022 05:15:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826298#M326395</guid>
      <dc:creator>xyxu</dc:creator>
      <dc:date>2022-07-31T05:15:29Z</dc:date>
    </item>
    <item>
      <title>Re: How to vertically align the right-hand side of comments in program header?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826314#M326396</link>
      <description>&lt;P&gt;Not in an editor supplied by SAS that I am aware of.&lt;/P&gt;
&lt;P&gt;Some people use other-than-SAS-supplied editors that have features that do that. Others insert spaces manually and use a monospace font.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The Enhanced Editor in Display Manager (sometimes called Base or PC SAS) with the Ctrl-/ key will put /* */ comment characters at the start and end of each line of a block of highlighted text. So the padding with spaces at the end is sometimes not too much headache.&lt;/P&gt;</description>
      <pubDate>Sun, 31 Jul 2022 06:06:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826314#M326396</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2022-07-31T06:06:23Z</dc:date>
    </item>
    <item>
      <title>Re: How to vertically align the right-hand side of comments in program header?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826320#M326398</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/99650"&gt;@xyxu&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Good question. Maybe they use a large "Tab size" in the Enhanced Editor Options (Tools → Options → Enhanced Editor...). For example, with a setting of 83 (spaces) I can place the cursor exactly where the closing "&lt;FONT face="courier new,courier"&gt;*/&lt;/FONT&gt;" is located in your example &lt;EM&gt;with a single keystroke&lt;/EM&gt;&amp;nbsp;after a shorter line of text (where "shorter" can be anything between 0 and 82 characters). If the "Insert spaces for tabs" checkbox is &lt;EM&gt;not&lt;/EM&gt; selected, those closing "&lt;FONT face="courier new,courier"&gt;*/&lt;/FONT&gt;" characters &lt;EM&gt;do not move&lt;/EM&gt; even if the comment text is edited and its length changes (within the range of 0 to 82 characters).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The horizontal border lines and separators ("&lt;FONT face="courier new,courier"&gt;/* ----&lt;/FONT&gt;...") could be created easily with a user-defined keyboard macro. Also an entire blank program header can be created that way or loaded from disk (with the checkbox "Replace tabs with spaces on file open" &lt;EM&gt;not&lt;/EM&gt; selected).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Personally, I don't like tabs in my code files so I don't use the above settings. But for those alignment purposes they might come handy.&lt;/P&gt;</description>
      <pubDate>Sun, 31 Jul 2022 10:41:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826320#M326398</guid>
      <dc:creator>FreelanceReinh</dc:creator>
      <dc:date>2022-07-31T10:41:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to vertically align the right-hand side of comments in program header?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826322#M326399</link>
      <description>&lt;P&gt;I did that extensively when I was employed at SAS. I used emacs as my editor along with some customized commands that made it easy. As a &lt;STRONG&gt;primitive&lt;/STRONG&gt; alternative, create an otherwise blank line with just the leading /* and */, then copy it multiple times and type over the blanks using overwrite. That said, if you don't have specialized commands for it, it is much easier not to do it.&lt;/P&gt;</description>
      <pubDate>Sun, 31 Jul 2022 12:03:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826322#M326399</guid>
      <dc:creator>WarrenKuhfeld</dc:creator>
      <dc:date>2022-07-31T12:03:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to vertically align the right-hand side of comments in program header?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826323#M326400</link>
      <description>&lt;P&gt;In my EG Enhanced Editor, I had a keyboard macro which would write the complete program header, including the nicely formatted comment block. I would then fill it in replace mode.&lt;/P&gt;</description>
      <pubDate>Sun, 31 Jul 2022 12:37:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826323#M326400</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2022-07-31T12:37:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to vertically align the right-hand side of comments in program header?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826324#M326401</link>
      <description>&lt;P&gt;My advice is don't bother.&amp;nbsp; It does not really make the comments any easier to read.&amp;nbsp; And it definitely makes them much harder to keep up to date.&amp;nbsp; I have seen too many programs that failed because one of those * or */ characters at the end of the line got pushed off the screen and so the programmer never noticed it was there.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you insist on creating such things then use the normal old program editor in SAS Display Manager it will let you type */ in column 75 without typing anything before it.&amp;nbsp; That feature does not exist in the "Enhanced" program editor.&lt;/P&gt;</description>
      <pubDate>Sun, 31 Jul 2022 13:52:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826324#M326401</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2022-07-31T13:52:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to vertically align the right-hand side of comments in program header?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826346#M326410</link>
      <description>&lt;P&gt;I'm with&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/159"&gt;@Tom&lt;/a&gt;&amp;nbsp; on this one. This is how I do it: it is still as tidy but you don't waste time having comment blocks on each line:&lt;/P&gt;
&lt;DIV id="tinyMceEditorSASKiwi_0" class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SASKiwi_1-1659302888395.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73938i3DD72AA4B397B609/image-size/medium?v=v2&amp;amp;px=400" role="button" title="SASKiwi_1-1659302888395.png" alt="SASKiwi_1-1659302888395.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 31 Jul 2022 21:28:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-vertically-align-the-right-hand-side-of-comments-in/m-p/826346#M326410</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2022-07-31T21:28:35Z</dc:date>
    </item>
  </channel>
</rss>

