Commit graph

2761 commits

Author SHA1 Message Date
Russ Cox
26c6b25795 devdraw: avoid deadlock on pre-Mojave macOS 2019-04-05 15:04:10 -04:00
Martin Kühl
dfac95269a acme: Update tag after receiving menu/nomenu control event (#251) 2019-04-05 14:45:56 -04:00
Xiao-Yong
0308e1f010 devdraw: fix cocoa metal _flushmemscreen for invalid rectangles (#240)
It is possible to receive multiple screen resize events, and resizeimg
would be called for different sizes, before _flushmemscreen actually
gets called with rectangle sizes different from the most recent
resizeimg call.  The size mismatch would trigger illegal memory
access inside _flushmemscreen.

This commit protects _flushmemscreen by returning early if the requested
rectangle is outside of the current texture rectangle.
2019-04-05 14:44:47 -04:00
Jacob Vosmaer
4d3c36cce4 devdraw: respond to windowDidBecomeKey on darwin (#239)
Fixes bug where devdraw does not "notice" mouse position after task
switch. Fixes https://github.com/9fans/plan9port/issues/232.
2019-04-05 14:43:21 -04:00
Russ Cox
047fd92174 page: handle EPS without showpage 2019-02-25 09:45:53 -05:00
Russ Cox
3ad4afbe82 rio: delete ancient Imakefile (use mk instead)
Fixes #235.
2019-02-01 13:20:49 -05:00
Russ Cox
43f1873709 acme: drop trailing spaces during Put of auto-indent window
Auto-indent mode leaves trailing spaces on blank lines
as you type past them, so silently elide them from the
window content as it gets written back to disk.

Another option would be to remove them from the
window entirely during Put, but they're actually nice
to have while editing, and to date Put has never
modified the window content.
2019-02-01 13:20:46 -05:00
Russ Cox
16d0081989 libdraw: redo default font construction to be hidpi-safe
If $font is not set, the default font is constructed from
font data linked into every libdraw binary. That process
was different from the usual openfont code, and so it was
not hidpi-aware, resulting in very tiny fonts out of the box
on hidpi systems, until users set $font.

Fix this by using openfont to construct the default font,
by recognizing the name *default* when looking for
font and subfont file contents. Then all the hidpi scaling
applies automatically.

As a side effect, the concept of a 'default subfont' is gone,
as are display->defaultsubfont, getdefont, and memgetdefont.
2018-11-16 00:03:24 -05:00
Martin Kühl
3ebbb99ce3 file: recognize Mach-O binaries and Java class files 2018-11-15 22:12:48 -05:00
Martin Kühl
3ae09bee86 file: add missing newlines to file types 2018-11-15 22:11:47 -05:00
Tobias Heinicke
a309537fdc paint: add drawing program from 9front (#112)
Paint first appeared in 9front. The 9front license is reproduced
in the related source files - the original repository is located at
https://code.9front.org/hg/plan9front.
2018-11-15 22:10:26 -05:00
Russ Cox
c63d31a8c1 rio: make 'mk all' explain why it does nothing on non-x11 systems
Fixes #98.
2018-11-15 22:05:53 -05:00
Jacob Vosmaer
3d6fc088f0 devdraw: remove os x 10.5 compatibility code 2018-11-15 22:03:27 -05:00
Russ Cox
43b0d532bd acme: add 32x32 boxcursor
The only difference from the upscaled 16x16
is a one-pixel adjustment in the offset position,
but this at least exercises setcursor2.
2018-11-15 20:52:18 -05:00
Russ Cox
7d43dde539 devdraw: add Cursor2 support on macOS 10.14 Mojave
This replaces the pixel-art scaling algorithm used for upscaling before.
The results were not crisp enough to serve as everyday cursors.
2018-11-15 20:39:35 -05:00
Russ Cox
be0a15c47b tweak: add support for Cursor2 2018-11-15 20:39:35 -05:00
Russ Cox
8581c2b567 libdraw: add Cursor2, a 32x32 high-res cursor
Also add setcursor2, esetcursor2, and draw protocol encoding.
Calls to the old setcursor, esetcursor create a 32x32 by
pixel doubling when needed.
2018-11-15 20:39:35 -05:00
Xiao-Yong Jin
9af9ceca26 devdraw: rewrite the Cocoa screen using Metal
Add a new macOS cocoa screen, cocoa-screen-metal.m.
Rewrite the macOS cocoa drawing code to use the builtin runloop,
and use Metal to push pixels with CAMetalLayer.

Remove all of the deprecated code, and simplify some of the logic.
Modify mkwsysrules.sh such that the new code is used only when
the system version is equal or higher than 10.14.

Allow touch events to simulate mouse clicks:
three finger tap for the middle mouse button;
four finger tap for the 2-1 chord.

Support Tresize.

Scale 16x16 Cursor up to 32x32 with an EPX algorithm.

Support macOS input sources including the basic dead keys and the
advanced CJK input methods.

Increase the communication buffers in cocoa-srv.c to allow more
input, especially for long sentences prepared by the macOS input
souces.
2018-11-15 20:39:35 -05:00
Zach Scott
de43b1629d upas/smtp: fix TLS connections (#163)
Both `upas/nfs` and `upas/smtp` call the currently broken `tlsClient()`
from libsec. This commit copies a fix from upas/nfs into upas/smtp.

In `imapdial()`, upas/nfs replaces a process call for tlsClient with
`stunnel3` when not on Plan 9. upas/smtp calls tlsClient directly
as a function, so imapdial was copied into mxdial.c as `smtpdial()`,
and tlsClient+dial replaced with a call to smtpdial.
2018-11-14 00:24:07 -05:00
Gabriel Díaz
000c1a3b19 devdraw: set displaydpi on devdraw x11 attach (#178)
See https://plan9port-review.googlesource.com/c/plan9/+/1470
for discussion of the approach, especially Michael Stapleberg's comment:

Note that chromium, firefox and others have tried this and then switched to using the Xft.dpi X resource, see e.g. https://code.google.com/p/chromium/codesearch#chromium/src/chrome/browser/ui/libgtk2ui/gtk2_ui.cc and especially http://sources.debian.net/src/gnome-settings-daemon/3.18.2-1/plugins/xsettings/gsd-xsettings-manager.c/?hl=824#L80 for some anecdata about why this approach doesn’t work out.

The Xft.dpi resource is being set accurately by desktop environments (GNOME, KDE, …) and can easily be changed by users of niche window managers by editing ~/.Xresources.

I suggest we check only Xft.dpi, without considering the DPI environment variable or the monitor width/height.
2018-11-14 00:19:29 -05:00
Russ Cox
d3f21b709e 9term: make 9term -l invoke $SHELL with -l 2018-11-14 00:13:01 -05:00
iru-
ed959cfba3 fontsrv: increase x11 font height scale (#111) 2018-11-14 00:01:04 -05:00
Xiao-Yong
a9e66ffa4e devdraw: make ctrl generate 1-click while mouse down (#119)
This makes 2-1 chords possible with touchpad on a mac laptop.
2018-11-13 23:57:56 -05:00
Xiao-Yong
c82e11b24e fontsrv: x11 uses FC_POSTSCRIPT_NAME (#174)
This makes fontsrv use the PostScript font names on X11.
The PostScript font names contains only alphanumeric and
hyphens.  This allows us to use the Font command in acme.
It also matches the font names used by fontsrv on macOS,
which has been using PostScript font names.
2018-11-13 23:13:15 -05:00
Fazlul Shahriar
76b9347a5f acme: avoid division by zero when resizing col (#189)
To reproduce, create a column with at least two windows and resize
acme to have almost zero height.
2018-11-13 23:11:31 -05:00
Xiao-Yong
2419c93438 fontsrv: disable font smoothing on osx (#196)
macOS Mojave version 10.14 starts to disable font smoothing.
We disable font smoothing for OSX_VERSION >= 101400 to match the
system default font rendering.
It also makes the font rendering on macOS similar to that on X11.
2018-11-13 23:09:59 -05:00
Xiao-Yong
014fd65a5c 9term: fix getpts on FreeBSD 11.2 (#199)
Opening /dev/ptyXX files fails on recent
FreeBSD versions.

Following the same fix being applied to
Linux, OpenBSD, and Darwin, we use openpty
to open a pseudoterminal in openpts.
2018-11-13 23:09:10 -05:00
Fazlul Shahriar
48da9bd71d fontsrv: copy some fixes from OS X to X11
* Avoid allocating empty images by adding 1 to width/height. This was
  crashing fontsrv. The total width of the subfont image can be zero
  even if the characters are present in the font. For example, all the
  characters in x0300.bit (part of "Combining Diacritical Marks" Unicode
  block) have zero width.
* Make sure U+0000 is always present in the font, otherwise libdraw
  complains with: "stringwidth: bad character set for rune 0x0000 in ..."
* Use the same fallback glyph (pjw face) as OS X. This also fixes a bug
  where advance was set to the total width of subfont instead of the
  character.

Update #125 (most likely fixes the crash if in X11)

Change-Id: Icdc2b641b8b0c08644569006e91cf613b4d5477f
2018-10-05 23:38:31 +02:00
Charles Collicutt
db27122d39 upas/nfs: correctly quote IMAP LOGIN arguments
According to RFC 3501 the arguments to the LOGIN command should be
quoted strings (or length prefixed string literals). Without quoting,
authentication to some IMAP servers (e.g. Dovecot) will fail.
2018-10-05 18:15:28 +02:00
David du Colombier
93c75d2bad grep: update from Plan 9
This change fixes a segfault in grep -e when no argument
has been provided. Thanks to Sean Hinchee for reporting
this issue.

Fixes #186.
2018-10-01 17:20:35 +02:00
David du Colombier
de3b6d5848 libregexp: include stddef.h in lib9.std.h
Commit 2d82ef9d98 added ptrdiff_t in regcomp.c.
However, this change broke the build of the Unix
package because ptrdiff_t is defined in stddef.h.
2018-09-29 15:59:31 +02:00
Martin Kühl
a82a8b6368 acme: Apply each -/+ only once (#156)
When plumbing an address like `3-`, Acme selects line 1,
and similarly `3+` selects line 5.
The same problem can be observed for character addresses (`#123+`)
but _not_ for ones like `+`, `.+` or `/foo/+`:
The problem only occurs when a number is followed by a direction (`-`/`+`).

Following along with the example `3-` through `address` (in addr.c):
We read `3` into `c` and match the `case` on line 239.
The `while` loop on line 242ff reads additional digits into `c`
and puts the first non-digit back by decrementing the index `q`.
Then we find the range for line 3 on line 251 and continue.

On the next iteration, we set `prevc` to the last `c`,
but since that part read ahead _into `c`_,
`c` is currently the _next_ character we will read, `-`,
and now `prevc` is too.

Then in the case block (line 210) the condition on line 211 holds
and Acme believes that it has read two `-` in sequence
and modifies the range to account for the “first” `-`.
The “second” `-` gets applied after the loop is done, on line 292.

So the general problem is:
While reading numbers, Acme reads the next character after the number into `c`.
It decrements the counter to ensure it will read it again on the next iteration,
but it still uses it to update `prevc`.

This change solves the problem by reading digits into `nc` instead.
This variable is used to similar effect in the block for directions (line 212)
and fills the role of “local `c` that we can safely use to read ahead” nicely.
2018-09-19 23:19:36 +10:00
Igor Burago
df2d9ec9d1 fontsrv: omit box-drawing characters from line struts on macOS
For some fonts, using box-drawing characters in the representative
text for computing the line height results in it being uncomfortably
high. Replace them with accented capitals and tall lower-case letters
which lead to a more conservative increase in the line height.

Fixes #162.
2018-06-26 23:24:22 +02:00
Xiao-Yong Jin
03a8ec739a libdraw: fix error in the previous commit 2018-03-27 18:11:37 +02:00
Xiao-Yong Jin
96025b1ec8 mc: fix crash in acme with hidpi display 2018-03-27 15:16:10 +02:00
Xiao-Yong Jin
75ea8515a5 samterm: free some getenv results 2018-03-27 15:03:12 +02:00
Xiao-Yong Jin
edfe3c016f sam: freetmpstr instead of free 2018-03-27 15:03:12 +02:00
Xiao-Yong Jin
dc2a17b95c libdraw: fix some memory leaks in font handling 2018-03-27 15:03:12 +02:00
Xiao-Yong Jin
a3ec102dc7 fontsrv: fix some memory leaks 2018-03-27 15:03:12 +02:00
Xiao-Yong Jin
b2f6769830 devdraw: fix some memory leaks in x11 2018-03-27 15:03:12 +02:00
Xiao-Yong Jin
7ca1c90109 acme: fix some memory leaks 2018-03-27 15:03:12 +02:00
Xiao-Yong Jin
96dc233091 fontsrv: enlarge drawing buffer for subfonts on macOS
Double the width returned by CTFontGetBoundingBox when drawing.
Add box drawing characters for determining the line height.
Call freememimage(1) for the character memimage.

Fixes #18.
Fixes #120.
Fixes #146.
2018-03-27 15:02:33 +02:00
Xiao-Yong Jin
a5b24c22a8 mount, 9pfuse: detect macports installed osxfuse
MacPorts installs osxfuse under /opt/local.
2018-03-27 15:01:46 +02:00
Mechiel Lukkien
4ebaf18e92 fontsrv: skip only the surrogate pairs
fontsrv wasn't rendering fontawesome icons,
which uses the private use area around 0xf000.
2018-03-23 12:05:33 +01:00
Ray Lai
d579124682 9pserve: fix memory leak in warning 2018-03-23 11:55:19 +01:00
Martin Kühl
cfa9a6dfa1 9term: Set TERM_PROGRAM to termprog
TERM_PROGRAM is the customary way to identify which kind of terminal
emulator program one uses on macOS.
This change sets TERM_PROGRAM to termprog since both variables are used
for the same purpose.
2018-03-23 10:41:43 +01:00
Xiao-Yong Jin
112744e54b 9pfuse: retries read(3) upon EINTR
read(3) sometimes errors with EINTR on macOS over slow connections.
9pfuse(1) now retries read(3) instead of sysfatal(3)ing.
2018-03-23 10:36:08 +01:00
David du Colombier
4798a8a556 9pfuse: fix handling of access mode (thanks Kenji Arisawa)
Fixes #81.
2018-02-05 21:14:32 +01:00
Bakul Shah
da8a485fc1 auxstats: get network stats in a portable manner on FreeBSD
as the old grody way doesn't work any more on FreeBSD-10 and later.
2018-01-23 09:00:53 +01:00
Ray Lai
019be4481f rc: use proper type for storing ulimit values
rc on amd64 stores ulimit values as 32-bit int, but the limits on
OpenBSD amd64 can exceed 2^31, so "ulimit -a" shows some values as
negative. This is a problem when I want to increase my ulimit but
the hard ulimit values are printed as negative.
2018-01-17 17:49:47 +01:00
Russ Cox
60f06594cc gview: fix int vs ulong confusion causing silent exit 1 at startup 2018-01-03 09:49:11 -05:00
Russ Cox
2023d484f2 9term: re-enable sys: child note for child processes
Fixes #6.

Change-Id: Id9950f59c7970575866a7c22a69bfbf3a271f2bb
2017-11-27 11:10:27 +01:00
Russ Cox
3d6e5cb56a acme: preserve window position and selection during Get
Before, executing Get in a file rewound the window offset and
selection to the start of the file.

After this CL, Get preserves the window offset and selection,
where preserve is defined as "the same line number and rune
offset within the line". So if the window started at line 10
before and the selection was line 13 chars 5-7, then that
will still be true after Get, provided the new content is large
enough.

This should help the common situation of plumbing a
compiler error, realizing the window is out of date,
clicking Get, and then losing the positioning from the
plumb operation.
2017-11-02 12:01:14 -04:00
Russ Cox
ff9d331db4 acme: free buf in checksha1
Thanks to Lorenzo Beretta for noticing.
2017-10-14 19:51:10 -04:00
David du Colombier
7321ed031c 9term: fix getpts on macOS 10.13
Since macOS 10.13, opening the /dev/ptyXX files
always return ENOENT.

Consequently, we changed getpts to use openpty to
open a pseudoterminal, like on Linux and OpenBSD.

Fixes #90.
Fixes #110.
2017-10-13 10:26:51 +02:00
David du Colombier
a6a3528868 upas/nfs: fix warnings
decode.c:146:8: warning: variable ‘argv’ set but not used
fs.c:953:47: warning: variable ‘reset’ set but not used
imap.c:348:6: warning: variable ‘prefix’ set but not used

Updates #114.
2017-10-13 10:16:20 +02:00
Russ Cox
67dbeee5fe acme: check file content before declaring file "modified since last read"
Bad remote file systems can change mtime unexpectedly,
and then there is the problem that git rebase and similar
operations like to change the files and then change them back,
modifying the mtimes but not the content.

Avoid spurious Put errors on both of those by checking file
content.

(False positive "modified since last read" make the real ones
difficult to notice.)
2017-10-10 13:51:24 -04:00
Rudá Moura
680c57a15c devdraw: fix build on macOS < 10.12
After making the build on macOS silent on commit 310ae03,
the build was broken on macOS lesser than 10.12 (Sierra).

This commit conditionally checks the version the of the
SDK before using the defined values for silent build.

Fixes #66.
2017-10-09 10:26:14 +02:00
Leah Neukirchen
c665ab76a8 xd: add -R for runewise dump
Ported from Plan 9 2013-05-21.
b377a116d1

Closes #16.
2017-10-01 11:46:06 +02:00
Kare Nuorteva
b3336e5cbb all: remove .cvsignore files
Rename following .cvsignore files to .gitkeep since they are
required by the build (directories must exist before build):
	- bin/fossil/.gitkeep
	- bin/fs/.gitkeep
	- bin/venti/.gitkeep

Change-Id: I9c2865058480cffb3a4613f25e2eca1f7e5578c0
2017-09-14 17:25:17 +02:00
David du Colombier
a8a775abbe lib9: import frand function from Plan 9
Fixes #15.
2017-09-01 22:51:14 +02:00
David du Colombier
bb044732c6 svgpic: fix warnings
plsvg.c:291:21: warning: variable ‘y2’ set but not used
plsvg.c:291:17: warning: variable ‘x2’ set but not used
2017-09-01 22:37:59 +02:00
David du Colombier
cf303e5baa libmach: initialize ss variable in stabsline2pc function
Fixes #58.
2017-09-01 22:37:05 +02:00
Russ Cox
a399388593 all: update site from swtch.com to 9fans.github.io 2017-09-01 13:25:20 -04:00
Russ Cox
a9e20eb10a ed: allow larger temp files
Requested by rob.
2017-09-01 12:06:25 -04:00
Michael Stroucken
4a8c0c75ff venti: fix venti graph on 64-bit
A pixel is 32 bits wide in RGBA, regardless of system's word size.

Change-Id: Iea36a8dafdec9ce8d593f944ef5ed1ea08e11d25
Reviewed-on: https://plan9port-review.googlesource.com/2980
Reviewed-by: David du Colombier <0intro@gmail.com>
2017-07-23 11:11:56 +00:00
Russ Cox
b15fd97627 acme: implement Cmd-Shift-Z for Redo on Mac
Change-Id: Ie9332ed473609bd6ca156be0843dc5411cbf7b93
Reviewed-on: https://plan9port-review.googlesource.com/2941
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-07-16 02:24:41 +00:00
Russ Cox
00b50225c2 devdraw: fix Mac Kcmd+Shift
Change-Id: Ide32a9397701085b17fbd42f0866eb3de11e4190
Reviewed-on: https://plan9port-review.googlesource.com/2940
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-07-16 02:24:34 +00:00
Russ Cox
711336c348 fontsrv: avoid quote mapping on fonts with indistinguishable quotes
Fixes #86.

Change-Id: Id487219a0fcfdb68133fc81b11383365a1431c1c
Reviewed-on: https://plan9port-review.googlesource.com/2922
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-06-19 13:58:51 +00:00
Russ Cox
1f1ab4ccbb lib9: fix needsrcquote
As written, it is passing a rune to strchr, which likely ignores
all but the bottom 8 bits of the rune. Long-standing Plan 9 bug too.

Fixes #87.

Change-Id: I6a833373b308bed8760d6989972c7f77b4ef3838
Reviewed-on: https://plan9port-review.googlesource.com/2921
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-06-19 13:51:23 +00:00
Russ Cox
3ebbd193dc svgpic: new program to convert pic to svg
This is an experiment.
Like tpic it's a copy-and-paste fork of pic.

Change-Id: Ia22772bd5881c7904a6d8f8e0b46fde8cea89cbd
Reviewed-on: https://plan9port-review.googlesource.com/2920
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-06-19 13:51:14 +00:00
Dan Cross
c976381d67 factotum: Fix an operator precedence bug in the secstore code
`==` is higher precedence than `&`. Parenthesize.

Change-Id: I2c7ee588fea0d8a66e1c8424f26630015388d61a
Signed-off-by: Dan Cross <cross@gajendra.net>
Reviewed-on: https://plan9port-review.googlesource.com/2860
Reviewed-by: Gleydson Soares <gsoares@gmail.com>
2017-05-05 20:04:17 +00:00
Dan Cross
9e52ea8a29 yacc: Fix a bug from at least 1995.
Fix a bug folding newlines in strings constants in C code snippets
in YACC.  This code has existed since at least 2nd Edition Plan 9.

Change-Id: Iba17b89a6529ac9fa6610bf0b44f551904174c26
Signed-off-by: Dan Cross <cross@gajendra.net>
Reviewed-on: https://plan9port-review.googlesource.com/2840
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-04-21 14:09:47 +00:00
Ray Lai
94b38bdb72 libdraw: replace hand-rolled realloc, preventing buffer overflow.
The original buffer is f->nsubf*sizeof *subf bytes (oldsize) large.
Once it's full, a new buffer of (f->nsubf+DSUBF)*sizeof *subf
(newsize) is mallocated.  Unfortunately memmove() reads (newsize)
bytes from the original (oldsize) buffer, causing a buffer overflow.

By switching to realloc(), we don't need to do buffer size calculation,
memmoving, and freeing of the original buffer.

Change-Id: Ibf85bc06abe1c8275b11acb1d7d346a14291d2cd
Reviewed-on: https://plan9port-review.googlesource.com/1520
Reviewed-by: Gleydson Soares <gsoares@gmail.com>
2017-04-08 00:06:42 +00:00
Ray Lai
669713d43f 9term: Add missing parentheses, preventing buffer overflow.
(el-sr) is the string length and (sizeof wdir - strlen(name) - 20)
is the buffer size. When the string length is greater than the
buffer size, the beginning of the string is supposed to be trimmed
to fit in the buffer size. Unfortunately a pair of parentheses were
missing, pointing sr outside the buffer, and the for loop below
then reads outside the buffer. For certain binary data printed in
a window, it causes a segfault.

Change-Id: Iffeaa348260ee2a5a36d9577308fb8d1c1688d05
Reviewed-on: https://plan9port-review.googlesource.com/1540
Reviewed-by: Gleydson Soares <gsoares@gmail.com>
2017-04-08 00:04:32 +00:00
James Porter
9f34853f7c 9pfuse: support osxfuse>=3.3.0
Change-Id: Ibca68261016b0f588e169e9f319748b5ba7d15ac
Reviewed-on: https://plan9port-review.googlesource.com/2700
Reviewed-by: michaelian ennis <michaelian.ennis@gmail.com>
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-02-10 13:37:44 +00:00
Russ Cox
c819ee640c 9term: c nits
Change-Id: Ia18ebb28f24bc69f404004896f9ce54ddb53faf9
Reviewed-on: https://plan9port-review.googlesource.com/2782
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-01-09 15:44:30 +00:00
Dave Presotto
be7485e1da cmd/9term: A hack because I'm constantly getting confused about ^C vs fn+delete
Since Google (and a lot of the outside) is so engrained with using
^C as interrupt, I'd like to be able to use it in 9term if I've
stty'd my intr to ^C. Without this, hitting ^C still works but if
the program behind the window isn't reading from /dev/cons, it won't
take effect till after I hit a newline which is often very confusing.

I know this is a hack since it only works if I stty intr ^C but that
seems the only other character that gets used anyways.

Change-Id: I0597e63b2d7628f5668c648e6dba6f281e4b27fd
Reviewed-on: https://plan9port-review.googlesource.com/2742
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-01-09 15:42:59 +00:00
Dave Presotto
82112d0434 src/cmd: take fontsrv out of BUGGERED
Change-Id: Iac5726f13039fba818536dc375d38cc3e27aca3a
Reviewed-on: https://plan9port-review.googlesource.com/2741
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-01-07 18:18:46 +00:00
Russ Cox
310ae03327 all: fix or silence all INSTALL warnings on macOS
Should be a clean build now.

Change-Id: Id3460371cb5e8d4071f8faa9c2aec870d213a067
Reviewed-on: https://plan9port-review.googlesource.com/2781
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-01-06 21:37:31 +00:00
Russ Cox
9e0d3750c5 9term, win: work around bsd linker nonsense
Change-Id: Ifcef0636ee1e1fd0f9b06a8d1a99d58fae831318
Reviewed-on: https://plan9port-review.googlesource.com/2780
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-01-06 20:20:33 +00:00
Russ Cox
d296c18e37 9term, mc: conspire to handle hidpi displays
9term now uses the low bit of ws.ws_ypixel to signal
whether this is a hidpi display, and mc adjusts the font
it uses for columnation accordingly.

Makes 'lc' work right on hidpi displays.

Change-Id: I52928871ffb7f4c6fd6722f3d59f1836379148c6
Reviewed-on: https://plan9port-review.googlesource.com/2760
Reviewed-by: Russ Cox <rsc@swtch.com>
2017-01-06 15:36:59 +00:00
David du Colombier
657f699ef7 include: define _DEFAULT_SOURCE
Since glibc 2.20, the _BSD_SOURCE and _SVID_SOURCE macros are
deprecated in favor of the _DEFAULT_SOURCE macro.

See https://sourceware.org/glibc/wiki/Release/2.20#Packaging_Changes

Change-Id: I18dd6a698f3f5aa51d1e45bf53b031bb061e17e8
Reviewed-on: https://plan9port-review.googlesource.com/1500
Reviewed-by: David du Colombier <0intro@gmail.com>
2016-11-20 09:37:58 +00:00
David du Colombier
1b68dbef7b libregexp: various fixes
- Check before dereference.
- Fix memory leak
- Remove duplicate if statement.
- Remove trailing spaces.

Change-Id: I140a05c8f7006493dddae753aebfa5b4577c65ef
Reviewed-on: https://plan9port-review.googlesource.com/1301
Reviewed-by: Neven Sajko <nsajko@gmail.com>
Reviewed-by: Russ Cox <rsc@swtch.com>
2016-11-02 23:17:40 +00:00
Gleydson Soares
2d82ef9d98 fix segfaults on OpenBSD: int cannot hold all the values a ptrdiff_t can take.
Change-Id: I90806e6f2e46a94f38aa0a8a7038aa6599b448b3
Reviewed-on: https://plan9port-review.googlesource.com/2660
Reviewed-by: Russ Cox <rsc@swtch.com>
2016-11-02 23:16:21 +00:00
Russ Cox
c499ab911d fontsrv: do not try to look up surrogate pairs
Change-Id: Ib0a680e123ba02b41e1029e356543c24e8b4647e
Reviewed-on: https://plan9port-review.googlesource.com/1430
Reviewed-by: Russ Cox <rsc@swtch.com>
2016-01-22 11:52:32 +00:00
Gleydson Soares
009b0cb5eb auxstats: fix OpenBSD by using getifaddrs(3) instead of kvm(3)
Change-Id: I6a096ba24809a402911c30406d384d16c03fc96c
Reviewed-on: https://plan9port-review.googlesource.com/1410
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-12-08 16:41:13 +00:00
sqweek
6a93bd5c92 devdraw: cocoa: set window title on main thread
Change-Id: Ie818f9246f749a9d3293019a1e01be4ce7e368b9
Reviewed-on: https://plan9port-review.googlesource.com/1400
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-11-11 15:09:34 +00:00
Russ Cox
8db40354c5 win: local \r cancellation
Change-Id: I4becec052af58c5a52b777004867eb23023b9403
Reviewed-on: https://plan9port-review.googlesource.com/1391
Reviewed-by: Russ Cox <rsc@google.com>
2015-11-10 15:34:42 +00:00
Russ Cox
0d2dfbc84f 9term, win: better \r handling (thanks, git)
Change-Id: I75563b911b54d8957d2d004b9c27d0a2f8f043b3
Reviewed-on: https://plan9port-review.googlesource.com/1390
Reviewed-by: Russ Cox <rsc@google.com>
2015-11-10 15:34:06 +00:00
Russ Cox
44eb208829 mk: avoid infinite loop when targets are repeated
Fixes "mk -f /tmp/x.mk y x" or "mk -f /tmp/x.mk" where /tmp/x.mk is:

x y x: f
	echo hi

Change-Id: I7fa87dc4750c04fdba010b990c190722b432b333
Reviewed-on: https://plan9port-review.googlesource.com/1361
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-08-27 00:36:40 +00:00
Russ Cox
775cb933ec fontsrv: use 64 chars per subfont instead of 256
Makes loading faster, and makes larger sizes not too wide.

Change-Id: I076c83fdb9577c1e596de45558f38ea93e3a2a31
Reviewed-on: https://plan9port-review.googlesource.com/1360
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-08-27 00:36:32 +00:00
Gleydson Soares
71de840f05 upas/nfs: search for stunnele3 in $PATH
Do not hardcode stunnel directory path, just make sure that is installed
in user '$PATH'. it is required for 'mailfs -t' TLS support, so printout
an error string if it was not found.

Tested with latest stunnel version 5.17 on OpenBSD and macosx.

% mailfs -t imap.gmail.com ; echo $?
0

Change-Id: Icbd507c7efa81ef2aa7aed37bec5f639b37526cb
Reviewed-on: https://plan9port-review.googlesource.com/1280
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-06-29 02:25:42 +00:00
Aram Hăvărneanu
3f1c876e14 all: linux/arm64 port
Really trivial port.

Change-Id: Ib2e3ad48df555ca4bd9339ddf79a832be895bd95
Reviewed-on: https://plan9port-review.googlesource.com/1030
Reviewed-by: Russ Cox <rsc@google.com>
2015-06-03 15:34:38 +00:00
David du Colombier
7a6f3d9d6d libregexp: fix copy-paste error
Change-Id: I042d63ea62e2abd599bf9767acb3374bb39ddc7d
Reviewed-on: https://plan9port-review.googlesource.com/1050
Reviewed-by: Minux Ma <minux@golang.org>
Reviewed-by: Russ Cox <rsc@google.com>
2015-06-03 15:34:13 +00:00
Aram Hăvărneanu
37d81a2915 all: linux/mips port
Change-Id: I0af67bc44c7bb62a8e5a47eac597367f521f1c11
Reviewed-on: https://plan9port-review.googlesource.com/1210
Reviewed-by: Russ Cox <rsc@google.com>
2015-06-03 15:34:06 +00:00
Aram Hăvărneanu
0c2926638b all: fix openbsd build
Change-Id: I6eaeebc9b6a4d78ce07efe7680ba8f2eff16462f
Reviewed-on: https://plan9port-review.googlesource.com/1230
Reviewed-by: Minux Ma <minux@golang.org>
Reviewed-by: Russ Cox <rsc@google.com>
2015-06-03 15:31:44 +00:00
Sergiusz Urbaniak
fdf6ef3337 acme: add focus change to log
Currently new, put and del events are being logged.
This patch adds a focus event to the log
whenever the user changes the focus to another window.

This lets programs react to files being edited in acme
without the need of being restarted.

Change-Id: Idf35c0d7dbfca30e79724dc9f49e44c6a4eb6a1e
Reviewed-on: https://plan9port-review.googlesource.com/1140
Reviewed-by: Russ Cox <rsc@google.com>
2015-06-03 15:31:21 +00:00
marius a. eriksen
d52bdd3356 devdraw: plumb drag-n-dropped files
Change-Id: I7585870aee57c7482ebdd19c117be7982123ce79
Reviewed-on: https://plan9port-review.googlesource.com/1130
Reviewed-by: Russ Cox <rsc@google.com>
2015-06-03 15:26:27 +00:00
Gleydson Soares
25822e8da3 libdraw, acme: fix acme segfault triggered passing an invalid font
acme -f nosuchfont

Change-Id: Iaa727db02b43e63082130796ec97c0efb7fe2b19
Reviewed-on: https://plan9port-review.googlesource.com/1220
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-05-15 02:30:27 +00:00
Russ Cox
3aca22118d fontsrv: fix x11 build
Change-Id: I60eca10d7749ec71dc2ffbb0fbde564a1b711fa1
Reviewed-on: https://plan9port-review.googlesource.com/1180
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-02-18 14:46:24 +00:00
Russ Cox
4eac378eba devdraw: enable retina behavior by default on OS X
Change-Id: I243a1fe3f9ec0841570c4cd69c02be9cfd9ade50
Reviewed-on: https://plan9port-review.googlesource.com/1172
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-02-17 20:52:59 +00:00
Russ Cox
79555a9987 libdraw: refine hidpi font selection
Change-Id: Id1e6a2630713024a1925ad1341bb9c846f82e93e
Reviewed-on: https://plan9port-review.googlesource.com/1171
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-02-17 20:52:06 +00:00
Russ Cox
213fc4f6fb libdraw: autoscale fonts when moving between low and high dpi screens
Change-Id: I6093955b222db89dfe437fb723593b173d888d01
Reviewed-on: https://plan9port-review.googlesource.com/1170
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-02-17 20:51:23 +00:00
Russ Cox
77f23268f7 libdraw: add 2*font syntax for scaled fonts
An experiment.

Change-Id: I40660a211b8372701597d80f7e86917e94cccbaa
Reviewed-on: https://plan9port-review.googlesource.com/1161
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-02-17 05:58:37 +00:00
Russ Cox
32dc15fa62 fontsrv: use CoreText API on OS X
This gets us font fallback for free and avoids use of a
deprecated API that might go away some day.

Change-Id: I4b9b1a1ce3e6d98bfb407e3baea13f4adfe2c26a
Reviewed-on: https://plan9port-review.googlesource.com/1160
Reviewed-by: Russ Cox <rsc@swtch.com>
2015-02-17 05:00:09 +00:00
Ethan Burns
d67a3d3083 fontsrv: disable X11 hinting
Discussion at:
https://groups.google.com/d/topic/plan9port-dev/L7RVkXPmrdY/discussion
https://github.com/9fans/plan9port/pull/7

Change-Id: I4f3a6791436120388ad8798e519f5e8473dd9306
Reviewed-on: https://plan9port-review.googlesource.com/1095
2014-12-02 01:51:11 +00:00
Merlijn Wajer
9bcee1f034 9pfuse: Disable glibc workaround for O_LARGEFILE on ARM
9pfuse fails on ARM when O_LARGEFILE is supported.
glibc does define O_LARGEFILE properly on ARM,
and the value is different than what that this workaround suggests,
causing it to wrongly detect bad flags.

Change-Id: I02b0cc222ca7785c4b1739c3df3caa17cf7bc265
Reviewed-on: https://plan9port-review.googlesource.com/1094
Reviewed-by: Russ Cox <rsc@swtch.com>
2014-12-02 01:46:43 +00:00
Russ Cox
fff818fe87 libdraw, libframe, acme: fix, guard against inverted range in textsetselect
Credit to Roi Martin <jroi.martin@gmail.com> for noticing that
libdraw was being passed a negative string length and for finding the
sequence of keystrokes that make acme do it reproducibly.

Change-Id: If3f3d04a25c506175f740d3e887d5d83b5cd1bfe
Reviewed-on: https://plan9port-review.googlesource.com/1092
Reviewed-by: Russ Cox <rsc@swtch.com>
2014-12-02 01:18:40 +00:00
Roi Martin
d3a47e14e5 devdraw: fix title and "open in top" on OS X
On OSX 10.10, when you open an application that depends on devdraw, the
title bar only shows the first letter of the application's name. The
patch sets a default title as soon as the window is created, which
fixes this issue.

On OSX 10.10, when you open an application that depends on devdraw, this
application is opened in top of other windows, however the menu bar is
not updated. The patch calls topwin() at the end of makewin() in
src/cmd/devdraw/cocoa-screen.m .

Change-Id: Ie036928b5574c8df20ad8b2b54047e2f7a22bb41
Reviewed-on: https://plan9port-review.googlesource.com/1091
Reviewed-by: Russ Cox <rsc@swtch.com>
2014-12-02 00:51:49 +00:00
Russ Cox
c9ed52730b cmd: rename *.C to *.c
These were *.C back in 2003, before the 9 script, to avoid conflicts
with the system utilities. A later change renamed them, but that
change seems to have been lost during the hg->git conversion
because I ran the conversion on a case-insensitive file system.

Change-Id: Id32c99cb9571ef0e185c3cc9e8c8d6d5b48ca195
2014-11-17 11:21:06 -05:00
David du Colombier
6c7443a653 fix clang 3.4 warnings and ignore uninteresting ones
fixed warnings:
src/cmd/fossil/disk.c:37:14: warning: use of GNU 'missing =' extension in designator [-Wgnu-designator]
src/cmd/fossil/disk.c:38:14: warning: use of GNU 'missing =' extension in designator [-Wgnu-designator]
src/cmd/fossil/disk.c:39:14: warning: use of GNU 'missing =' extension in designator [-Wgnu-designator]
src/cmd/fossil/disk.c:40:13: warning: use of GNU 'missing =' extension in designator [-Wgnu-designator]
src/cmd/fossil/disk.c:41:14: warning: use of GNU 'missing =' extension in designator [-Wgnu-designator]
src/libndb/ndbreorder.c:41:55: warning: for loop has empty body [-Wempty-body]

ignored warnings:
src/cmd/acid/dbg.y:393:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/cmd/bc.y:1327:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/cmd/bc.y:1327:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/cmd/grep/grep.y:420:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/cmd/grep/grep.y:420:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/cmd/hoc/hoc.y:692:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/cmd/hoc/hoc.y:692:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/cmd/lex/parser.y:886:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/cmd/rc/syn.y:303:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/cmd/units.y:1003:9: warning: array index -1 is before the beginning of the array [-Warray-bounds]
src/libregexp/regcomp.c:19:16: warning: variable 'reprog' is not needed and will not be emitted [-Wunneeded-internal-declaration]

LGTM=rsc
R=rsc
https://codereview.appspot.com/158250043
2014-10-21 14:22:12 +02:00
Russ Cox
2763a6d832 venti/copy: fix bug writing directories that zero truncate
Found by nwf.

TBR=rsc
https://codereview.appspot.com/162860045
2014-10-21 07:25:13 -04:00
Russ Cox
72197f89d4 col: import from plan 9, by popular demand
TBR=rsc
https://codereview.appspot.com/158240043
2014-10-20 20:41:41 -04:00
David du Colombier
fd3496d3ef 9l: link with -lresolv on Linux
LGTM=rsc
R=rsc
https://codereview.appspot.com/136520044
2014-10-20 22:21:43 +02:00
David du Colombier
738e890b19 vbackup: fix compilation on NetBSD (thanks Álvaro Jurado)
On NetBSD 5.0 and upper, mount() require
data_len as a fifth argument.

LGTM=rsc
R=rsc
CC=elbingmiss
https://codereview.appspot.com/111600043
2014-08-06 14:43:21 +02:00
Russ Cox
f5ae255cc3 mc: use $termprog to identify 9term
TBR=rsc
https://codereview.appspot.com/112890043
2014-07-09 10:26:09 -04:00
David du Colombier
32c6e78c6c upas: fix nil pointer dereference
R=rsc
https://codereview.appspot.com/92650043
2014-06-05 18:46:28 +02:00
Russ Cox
c99867c9e0 upas/common: rename aux to auxx
TBR=rsc
https://codereview.appspot.com/107760043
2014-06-03 14:30:52 -04:00
Russ Cox
50ababbd55 acme: fix bufread crash due to typing-point scrolling
Acme tracks the most recent typing insertion point and
the home and end keys stop there on their way
up to the top or down to the bottom of the file.
That point should be iq1, and it should be adjusted
properly so that it's always between 0 and t->file->b.nc inclusive.
(This is all code from an external contributor, years old at this
point but new since Plan 9.)

Somehow, sometimes iq1 ends up a little beyond b.nc,
and when passed to textbacknl it crashes acme in bufread.
I can't see how that can happen but if it does, avoid the crash.

It's tempting to pull the insertion point code out entirely
but this is a little less invasive and should fix things for now.

TBR=rsc
https://codereview.appspot.com/107730043
2014-06-03 00:16:48 -04:00
Russ Cox
6400c9f20c acme: increase timer resolution to 10ms
We ran for a long time with 10ms kernel resolution,
so 10ms user space resolution here should be fine.
Some systems actually provide 1ms sleeps, which
makes this polling use a bit more cpu than we'd like.
Since the timers are for user-visible things, 10ms should
still be far from noticeable.

Reduces acme's cpu usage on Macs when plumber is missing
(and plumbproc is sleeping waiting for it to appear).

LGTM=aram, r
R=r, aram
https://codereview.appspot.com/99570043
2014-06-03 00:09:29 -04:00
Russ Cox
113ea95f7b undo CL 69070045 / 8539a916d98a
This breaks ^C in win windows, as expected.
People use ^C, win expects and handles ^C,
so I don't think we can just take it away.

I've noticed that it is broken but assumed my ssh
was screwed up.

If you want to make WindowsKey+C,X,V do the
operations, by analogy with command+C,X,V
on Mac, that's fine with me.

««« original CL description
acme: copy/cut/paste with ctl+c,x,v

LGTM=rsc
R=rsc
CC=plan9port.codebot
https://codereview.appspot.com/69070045

»»»

TBR=rsc
CC=burns.ethan, r
https://codereview.appspot.com/96410045
2014-05-19 09:39:34 -04:00
David du Colombier
bae34df843 upas: fix warnings
smtp.c:232: warning: comparison with string literal results in unspecified behavior
smtp.c:244: warning: comparison with string literal results in unspecified behavior
marshal.c:1179: warning: variable ‘err’ set but not used

LGTM=rsc
R=rsc
https://codereview.appspot.com/93290043
2014-05-15 06:28:54 +02:00
David du Colombier
954e03ccfe libndb: add AUTOLIB(resolv)
LGTM=rsc
R=rsc
https://codereview.appspot.com/97370043
2014-05-15 06:28:05 +02:00
Russ Cox
45f8ba5414 acme: fix two flush bugs in new log file
TBR=rsc
https://codereview.appspot.com/95010048
2014-05-05 22:28:03 -04:00
Russ Cox
4a3fb87264 acme: add log file in acme root directory
Reading /mnt/acme/log reports a log of window create,
put, and delete events, as they happen. It blocks until the
next event is available.

Example log output:

8 new /Users/rsc/foo.go
8 put /Users/rsc/foo.go
8 del /Users/rsc/foo.go

This lets acme-aware programs react to file writes, for example
compiling code, running a test, or updating an import block.

TBR=r
R=r
https://codereview.appspot.com/89560044
2014-04-30 12:14:29 -04:00
Russ Cox
833216fef8 acme: add comment for aligned writes
TBR=r
https://codereview.appspot.com/89510044
2014-04-19 13:44:06 -04:00
Russ Cox
1d2c3c3945 acme: use buffered i/o to write file
Bakul Shah has observed corrupted files being written
when acme writes over osxfuse to sshfs to a remote file system.
In one example we examined, acme is writing an 0xf03-byte
file in two system calls, first an 0x806-byte write and then a 0x6fd-byte
write. (0x806 is BUFSIZE/sizeof(Rune); this file has no multibyte UTF-8.)

What actually ends up happening is that an 0x806-byte file is written:

        0x000-0x6fd contains what should be 0x806-0xf03
        0x6fd-0x7fa contains zeros
        0x7fa-0x806 contains what should be 0x7fa-0x806 (correct!)

The theory is that fuse or sshfs or perhaps the remote file server is
mishandling the unaligned writes. acme does not seem to be at fault.

Using bio here will make the writes align to 8K boundaries,
avoiding the bugs in whatever underlying piece is broken.

TBR=r
https://codereview.appspot.com/89550043
2014-04-19 10:09:22 -04:00
Russ Cox
d213189122 acme: fix Get of dir in nameless window (thanks Colton Lewis)
TBR=r
https://codereview.appspot.com/89390043
2014-04-18 14:03:46 -04:00
Ethan Burns
4030a6c905 acme: copy/cut/paste with ctl+c,x,v
LGTM=rsc
R=rsc
CC=plan9port.codebot
https://codereview.appspot.com/69070045
2014-03-13 18:48:41 -04:00
Russ Cox
219cf22d68 acme, sam: handle >1GB files correctly
TBR=rsc
https://codereview.appspot.com/74060043
2014-03-13 18:46:28 -04:00
David du Colombier
63002b3e5a fix gcc 4.8 warnings
LGTM=rsc
R=rsc
https://codereview.appspot.com/33240044
2014-03-03 22:30:34 +01:00
David du Colombier
24b8994d3d fossil: fix p9p changes on view
LGTM=rsc
R=rsc
https://codereview.appspot.com/31130043
2014-03-03 22:23:07 +01:00
Shenghou Ma
20035ed43c all: DragonFly port.
Fix compilation problems, libdraw still doesn't work right yet.

LGTM=rsc
R=rsc
https://codereview.appspot.com/67820046
2014-02-27 23:17:47 -05:00
Russ Cox
042a069825 devdraw: clear altdown on focus out (thanks Ethan Burns)
TBR=rsc
https://codereview.appspot.com/53820044
2014-01-22 13:41:13 -05:00
David du Colombier
b29ebaab99 fossil: fix remaining warnings
R=rsc
https://codereview.appspot.com/15100044
2013-10-23 22:10:31 +02:00
Rob Pike
5a69e405fc acme: scroll a directory window when navigating if:
- the cursor is on the last line
        - the navigation would put the cursor over the tag of the following text

R=rsc
CC=smckean83
https://codereview.appspot.com/15280045
2013-10-22 16:47:48 -07:00
David du Colombier
075c3bdc54 xd: fix build by declaring swizz8
R=rsc
https://codereview.appspot.com/13982043
2013-09-26 22:34:05 +02:00
David du Colombier
25f54d6f52 fossil: cleanup mkfile
R=rsc
https://codereview.appspot.com/13988043
2013-09-26 22:33:27 +02:00
David du Colombier
68beda2144 fossil: import conf.rc
R=rsc
https://codereview.appspot.com/13983043
2013-09-26 22:31:57 +02:00
David du Colombier
3fcc209df9 fossil: cast Qid.vers, Dir.mode and Qid.mtime to u32int (thanks Tim Kack)
R=rsc
https://codereview.appspot.com/13981043
2013-09-26 22:31:11 +02:00
David du Colombier
3c612e13a1 fossil: fix various warnings
R=rsc
https://codereview.appspot.com/13980043
2013-09-26 22:30:24 +02:00
David du Colombier
b32de4ae73 fossil: required p9p changes
R=rsc
https://codereview.appspot.com/13352057
2013-09-26 20:12:45 +02:00
David du Colombier
4b57665805 fossil: move from liboventi to libthread and libventi
R=rsc
https://codereview.appspot.com/13504049
2013-09-23 23:16:25 +02:00
David du Colombier
6f4d00ee45 fossil: import from plan 9
R=rsc
https://codereview.appspot.com/7988047
2013-09-23 23:00:39 +02:00
Marius Eriksen
fea86f0639 acme: execute commands with / using shell
This allows commands in bin subdirectories.

R=rsc
CC=plan9port.codebot
https://codereview.appspot.com/13254044
2013-09-06 16:23:49 -04:00
Akshat Kumar
7603066e73 acme Mail: add Search command
Introduces the Search command for mailboxes.
Arguments passed are treated as one space-
separated string, passed on to mailfs' IMAP
search interface.

R=rsc, david.ducolombier
CC=plan9port.codebot
https://codereview.appspot.com/13238044
2013-09-06 16:19:57 -04:00
Akshat Kumar
951fef52c9 mailfs: allow spaces in box name
Mail services (such as Google Mail) will often have
directories with names that contain spaces. Acme
does not support spaces in window names. So, replace
spaces in mail directory names with the Unicode
character for visible space.

The code is a bit of an over-approximation and
generally non-optimal.

R=rsc, david.ducolombier, 0intro
CC=plan9port.codebot
https://codereview.appspot.com/13010048
2013-09-06 16:10:26 -04:00
Akshat Kumar
6541f1798b mailfs: support for UTF-8 searches
UTF-8 searches with the SEARCH command must
be conducted in two steps: the first sends
the SEARCH command with the length of the
UTF-8 encoded string and the second sends
the literal search term. The searches need
to not be quoted.

R=rsc, david.ducolombier, rsc, 0intro
CC=plan9port.codebot
https://codereview.appspot.com/13244043
2013-09-06 16:09:29 -04:00
Russ Cox
1670a244d9 devdraw: set window name to argv[0]
R=rsc
CC=r
https://codereview.appspot.com/12577043
2013-08-06 23:44:06 -04:00