Skip to content

Commit 9209cf1

Browse files
committed
Fix readme.md typos
1 parent 23d850c commit 9209cf1

File tree

1 file changed

+23
-12
lines changed

1 file changed

+23
-12
lines changed

readme.md

Lines changed: 23 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
[![Tag Version](https://img.shields.io/github/tag/dpsutton/resize-window.svg)](https://github.com/dpsutton/resize-window/tags)
88

99
## What it is ##
10+
1011
Resizing windows is a pain in emacs. You have to do an uncomfortable
1112
chord `C-x {`, `C-x ^`. Giving prefixes to make the jump larger than 1
1213
line means remembering `C-u <number> <terrible chord>`. I always
@@ -15,9 +16,10 @@ minor mode to easily adjust window sizes with familiar keys and
1516
without chords.
1617

1718
## How to use it ##
19+
1820
As soon as it gets polished a little further, it will hopefully be
1921
accepted to ELPA or something (I'm not too sure about all of the
20-
differences, ELPA, MELPA, marmalade, etc.
22+
differences, ELPA, MELPA, marmalade, etc.)
2123

2224
I've submitted for elpa and have a pending request to have copyright
2325
assigned. Until then, just drop it into your load path. I've found the
@@ -56,16 +58,20 @@ motions and cycle windows until everything is adjusted to how you like
5658
it.
5759

5860
## How to extend it ##
61+
5962
There are a few things that you can do. There are customizable variables:
6063
- resize-window-coarse-argument (default: 5)
6164
- resize-window-fine-argument (default: 1)
62-
- resizewindow-allow-backgrounds (default: t)
65+
- resize-window-allow-backgrounds (default: t)
66+
- resize-window-swap-capital-and-lowercase-behavior (default: nil)
67+
- resize-window-notify-with-messages (default: t)
6368

6469
Any of these can be customized by using `customize-group RET
6570
resize-window` or by setting the appropriate variable in your init.el
6671
file as normal: `(setq <var> <val>)`.
6772

6873
## What's even cooler ##
74+
6975
At the end of the day, this is really just a function dispatcher
7076
listening for key presses. So i've found a really nice workflow. I've
7177
bound resize-window to `C-c ;` and i've also added a new dispatch:
@@ -78,7 +84,9 @@ run helm-mini. Its trivial now to bounce around, resize windows and
7884
reset their sources. And since the help menu is dynamically generated,
7985
pressing ? displays this new choice automatically.
8086

81-
For convenience sake, you can use the helper method `resize-window-add-choice` to register your function without having to remember the structure of the list it will end up in. For example:
87+
For convenience sake, you can use the helper method `resize-window-add-choice`
88+
to register your function without having to remember the structure of the list
89+
it will end up in. For example:
8290

8391
(push '(?h (lambda () (dired "~/projects/clojure")) "Clojure home" nil))
8492
; is equivalent to
@@ -87,10 +95,9 @@ For convenience sake, you can use the helper method `resize-window-add-choice` t
8795

8896
; the allows-capitals argument is optional.
8997

90-
Further, there are alias, held in the `resize-window-alias-list` alist. It is
98+
Further, there are aliases, held in the `resize-window-alias-list` alist. It is
9199
currently defined as
92100

93-
94101
(defvar resize-windown-alias-list
95102
'((right ?f)
96103
(up ?n)
@@ -125,26 +132,29 @@ resize these buffers.
125132
![usage gif](images/navigate.gif)
126133

127134
## Bugs ##
135+
128136
- When in resize mode, there's a visual overlay over the current
129137
buffer to give some visual indication what's going on. However, if
130138
you have two copies of the same buffer open, both are
131139
overlayed. Would like to reduce this so that only the buffer you're
132140
working in is overlaid, regardless of how many copies are open
133141

134142
## Hopeful upcoming features ##
143+
135144
I can't promise any of these but these are the things I'm hoping to
136145
do:
137146

138147
- put overlays over *other* buffers rather than current one. This
139148
greys out other workspaces and leaves yours with full color,
140149
bringing your eye there. Just seems like a nice ergonomic touch.
141-
- DONE:allow customization to invert capital/non-capital behavior. Right
150+
- DONE: allow customization to invert capital/non-capital behavior. Right
142151
now, lower case selections move the window size by 1 and upper-case
143152
moves by 5. These should both be easy to customize and easy to
144153
*flip*. Ie, make the lowercase `n` make it bigger by 5 and the
145154
upper-case `N` increase by 1.
146155

147156
## Shout out ##
157+
148158
This is my first attempt at really doing anything in elisp and to get
149159
there, I drew lots of inspiration and organizational ideas and almost
150160
verbatim code from `ace-mode`. Ace mode is super super nice and my aim
@@ -153,17 +163,18 @@ than jumping. In fact, this might actually be better as a pull request
153163
to their package.
154164

155165
## How it works ##
166+
156167
Super simple architecture. There's an associative list called
157-
`resize-window-dispatch-alist` (the rm is prefix for resize-mode) that holds a
158-
simple data structure with the invocation-key, the function to call,
159-
documentation string to be shown as a message, and whether it should
160-
accept a capital letter as well as the lower-case letter.
168+
`resize-window-dispatch-alist` (the rm is prefix for resize-mode) that
169+
holds a simple data structure with the invocation-key, the function to
170+
call, documentation string to be shown as a message, and whether it
171+
should accept a capital letter as well as the lower-case letter.
161172

162173
The function `resize-window` is just a while loop listening for
163174
characters, checking if that character is associated to anything in
164175
the list and checking if `(+ char 32)` is associated to anything in
165176
the list (which is just the uppercase version (or is it? now its a
166177
bug)). If lower case matches, do it, if uppercase matches something,
167178
then make sure that's ok and do it but with the
168-
`resize-window-capital-argument` rather than
169-
`resize-window-default-argument`.
179+
`resize-window-uppercase-argument` rather than
180+
`resize-window-lowercase-argument`.

0 commit comments

Comments
 (0)