{"id":13862542,"url":"https://github.com/zk-phi/phi-rectangle","last_synced_at":"2025-04-14T13:05:29.660Z","repository":{"id":10508952,"uuid":"12695478","full_name":"zk-phi/phi-rectangle","owner":"zk-phi","description":"Another rectangle-mark command","archived":false,"fork":false,"pushed_at":"2020-09-11T02:13:19.000Z","size":1057,"stargazers_count":12,"open_issues_count":0,"forks_count":2,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-08-05T06:06:00.915Z","etag":null,"topics":["emacs"],"latest_commit_sha":null,"homepage":"","language":"Emacs Lisp","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zk-phi.png","metadata":{"files":{"readme":"Readme.org","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-09-09T07:27:51.000Z","updated_at":"2024-06-21T12:05:16.000Z","dependencies_parsed_at":"2022-08-30T17:41:56.590Z","dependency_job_id":null,"html_url":"https://github.com/zk-phi/phi-rectangle","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zk-phi%2Fphi-rectangle","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zk-phi%2Fphi-rectangle/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zk-phi%2Fphi-rectangle/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zk-phi%2Fphi-rectangle/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zk-phi","download_url":"https://codeload.github.com/zk-phi/phi-rectangle/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223634005,"owners_count":17176871,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["emacs"],"created_at":"2024-08-05T06:01:47.087Z","updated_at":"2024-11-08T04:35:08.208Z","avatar_url":"https://github.com/zk-phi.png","language":"Emacs Lisp","readme":"* phi-rectangle.el\n\nanother rectangle-mark command (rewrite of rect-mark)\n\n矩形選択コマンド\n\n** Screencast\n\n[[imgs/top.gif]]\n\n** Background\n\nThere are several previous works such as \"rect-mark\", \"cua-mode\",\netc. The motivation to write this command is as follows:\n\n- cua-mode has many functionalities such as \"delete-selection\",\n  \"shift-region\", and \"rectangle-mark\", but it seems too complex when\n  we just want to use \"rectangle-mark\".\n\n- cua-mode has also \"mark-multiple\"-like feature as a part of\n  \"rectangle-mark\". But we'd better use multiple-cursors.\n\n- rect-mark seems simple and clean, but too simple for me. For\n  example, to duplicate rectangle we must call following commands:\n\n  1. rm-set-mark [C-x r C-SPC]\n  2. rm-kill-ring-save [C-x r C-w]\n  3. yank-rectangle [C-x r y]\n\n  On the other hands, cua-mode can do it with:\n\n  1. cua-set-rectangle-mark [C-RET]\n  2. cua-copy-region [C-w]\n  3. cua-paste [C-y]\n\n  cua-mode unifies \"copy\" and \"copy-rectangle\", \"paste\" and\n  \"paste-rectangle\", etc. Very easy.\n\n- \"force\" option in rect-mark is somewhat annoying, Because we need to\n  delete trailing whitespaces manually.\n\n- rect-mark does not work perfectly with delete-selection-mode.\n\n\"phi-rectangle\" is based on rect-mark, but as easy-to-use as cua, and\nis also integrated with multiple-cursors.\n\n** Usage\n\nRequire this script\n\n: (require 'phi-rectangle)\n\nand call function =phi-rectangle-mode=. Then following commands are\navailable\n\n- [C-RET] phi-rectangle-set-mark-command\n\n  Activate the rectangle mark.\n\n- phi-rectangle-kill-region (replaces \"kill-region\")\n\n  A dwim version of \"kill-region\". If the rectangle mark is active,\n  kill rectangle. If the normal mark is active, kill region as usual.\n  Otherwise, kill whole line.\n\n- phi-rectangle-kill-ring-save (replaces \"kill-ring-save\")\n\n  A dwim version of \"kill-ring-save\" like \"phi-rectangle-kill-region\".\n\n- phi-rectangle-yank (replaces \"yank\")\n\n  A dwim version of \"yank\". If the last killed object is a rectangle,\n  yank rectangle. Otherwise yank a kill-ring item as usual.\n\n** multiple-cursors Integration\n\nWhen multiple-cursors is installed in your system, phi-rectangle does\nmore.\n\n- Convert killed-rectangle and fake cursors' kill-ring if proper.\n\n  [[imgs/mc1.gif]]\n\n- Invoke multiple-cursors-mode on delete-selection-mode to edit\n  multiple lines.\n\n  [[imgs/mc2.gif]]\n","funding_links":[],"categories":["Emacs Lisp"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzk-phi%2Fphi-rectangle","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzk-phi%2Fphi-rectangle","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzk-phi%2Fphi-rectangle/lists"}