{"id":126,"date":"2014-10-19T00:00:00","date_gmt":"2014-10-18T22:00:00","guid":{"rendered":"http:\/\/kurt.www.pinboard.jp\/blog\/?p=126"},"modified":"2014-09-06T17:13:27","modified_gmt":"2014-09-06T15:13:27","slug":"align-lines","status":"publish","type":"post","link":"http:\/\/kurt.www.pinboard.jp\/blog\/kurt\/126\/","title":{"rendered":"align lines"},"content":{"rendered":"<p>Usually lines are left aligned when writing in languages which use the alphabet. For certain formatting, however, it may be beneficial to right align or center some lines.<!--more--><\/p>\n<p>Easily done. Use <span style=\"color: green;\">ri<\/span> to right align the current line, <span style=\"color: green;\">le<\/span> to left align it and  <span style=\"color: green;\">ce<\/span> to center it.<\/p>\n<p>All three commands accept a range in front of them. So the command<br \/>\n<code>:.,+4 ri<\/code><br \/>\nwill right align (ri) the current (.) and next four (+4) lines.<\/p>\n<p>After <code>le<\/code> an optional indent can be specified.<br \/>\nAfter both <code>ri<\/code> and <code>ce<\/code> an optional line width to use for the calculation can be specified.<\/p>\n<table>\n<tbody valign=\"top\">\n<tr>\n<td style=\"background-color: lightyellow; color: green;\">:ri<\/td>\n<td>right align the line(s)<\/td>\n<\/tr>\n<tr>\n<td style=\"background-color: lightyellow; color: green;\">:le<\/td>\n<td>left align the line(s)<\/td>\n<\/tr>\n<tr>\n<td style=\"background-color: lightyellow; color: green;\">:ce<\/td>\n<td>center the line(s)<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n","protected":false},"excerpt":{"rendered":"<p>Usually lines are left aligned when writing in languages which use the alphabet. For certain formatting, however, it may be beneficial to right align or center some lines.<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[2],"tags":[10],"_links":{"self":[{"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/posts\/126"}],"collection":[{"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/comments?post=126"}],"version-history":[{"count":4,"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/posts\/126\/revisions"}],"predecessor-version":[{"id":130,"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/posts\/126\/revisions\/130"}],"wp:attachment":[{"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/media?parent=126"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/categories?post=126"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/kurt.www.pinboard.jp\/blog\/wp-json\/wp\/v2\/tags?post=126"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}