summary refs log tree commit diff
path: root/edit.c
diff options
context:
space:
mode:
Diffstat (limited to 'edit.c')
-rw-r--r--edit.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/edit.c b/edit.c
index d63678d..34b89fe 100644
--- a/edit.c
+++ b/edit.c
@@ -163,11 +163,13 @@ static void tabComplete(uint id) {
 		return;
 	}
 
+	bool colon = (tab.len >= 2 && buf[tab.pos + tab.len - 2] == L':');
+
 	delete(false, tab.pos, tab.len);
 	tab.len = n;
 	if (wcs[0] == L'\\' || wcschr(wcs, L' ')) {
 		reserve(tab.pos, tab.len);
-	} else if (wcs[0] != L'/' && !tab.pos) {
+	} else if (wcs[0] != L'/' && (!tab.pos || colon)) {
 		tab.len += 2;
 		reserve(tab.pos, tab.len);
 		buf[tab.pos + n + 0] = L':';
Implement word wrappingJune McEnroe 2018-08-06Use wchar_t strings for all of UIJune McEnroe vaswprintf is a nightmare. 2018-08-06Rename line editing functionsJune McEnroe 2018-08-05Initialize all possible color pairsJune McEnroe This is actually possible with use_default_colors! 2018-08-05Refactor color initializationJune McEnroe 2018-08-05Add ^L redrawJune McEnroe 2018-08-05Use 16 colors if availableJune McEnroe Fall back to using bold if there are only 8 colors. This also allowed bright background colors in 16-color terminals. I must port this system to torus. I'll be able to remove the awful termcap patch hack. 2018-08-05Limit parsed colors to number of mIRC colorsJune McEnroe Oh boy that's embarrassing. 2018-08-04Show source link on exitJune McEnroe 2018-08-04Implement line editing, scrollingJune McEnroe Don't really have a way to implement the M-* keys, and currently missing C-w. 2018-08-04Handle /topicJune McEnroe