[dev] [st] Multiple monitors dpi autoswitch

2017-12-28 Thread Amer
Hi, The problem: * two monitors with very different dpi -- FullHD 100 and UltraHD 274 * spawning new terminal has font size related to dpi of preffered monitor * moving spawned [st] window between monitors (e.g. in tiling WM) => text size requires adjusting by / Wish -- [st]

[dev] [st] ssh clipboard sync by escape sequence

2017-07-01 Thread Amer
Idea: seamlessly pull clipboard content from remote machine when using nvim/ranger When: copy text pieces between vim instances opened in multiple ssh servers Impl: xsel wrapper on each server => sync to host machine when piping into xsel * fallback to xsel if $DISPLAY is available (xset -q

Re: [dev] [ask] search binary file offset in file

2017-03-24 Thread Amer
gnored: inadequate Alg for mmap() is the most crucial part for performance after algorithm itself. As alg+mmap() must be optimized to SDD/RAM/LCache limitations and access type. On Fri, Mar 24, 2017 at 11:37:15PM +0300, Alexander Krotov wrote: On Fri, Mar 24, 2017 at 08:03:38PM +0200, Amer wrote: Does a

[dev] [ask] search binary file offset in file

2017-03-24 Thread Amer
Does anybody knows any cli tools which allows to search offset of one binary file inside another ? Find if ./chunk.bin contained and its offset inside ./dump.bin * simple case: 200kB inside 100MB * hard case: 2GB inside 100GB I thought this idea is as old as PC itself, but I couldn't find

Re: [dev] looking for a simple music player

2017-02-07 Thread Amer
I prefer ranger + mpv/cli for that. * filter/sort/tag/select by ranger * play selection/tag/yankbuf by mpv Maybe, the single desirable extension to that -- is to auto open narrow bar at bottom in split tmux window, to background mpv from ranger. But desire isn't too strong to actually

Re: [dev] Request for name suggestions: suckless video editor

2017-01-11 Thread Amer
I want the tools to have a common prefix of 2 to 4 characters plus a dash. Any other ideas of awesome arbitrary things, I cannot think of anything else that is not already used? Short names were exhausted, really?) At least AUR is free of them. eiv eivy evior eviour ouvie muv cvq veq yvi vidj

Re: [dev] [st] [PATCH] Converted "font" string to "fonts" array

2016-08-14 Thread Amer
I don't understand at all how you can apply this embedded-into-body patch with all tabs replaced by spaces and lines wrapped on 80. What magic I need for this? Anyway, reformatted patch cleanly applying to 0.7 in the attachment. diff --git a/config.def.h b/config.def.h index b41747f..638c3c5

[dev] [st] [PATCH] multiplexer (tmux integration)

2016-08-14 Thread Amer
I suppose this patch isn't mature enough, so you are welcome. Content * added -m/-M command line options to demand/ignore multiplexer (using only -m option to toggle defaults isn't robust enough) * config options to specify exec wrapper and finalizing commands * sessions are named after

Re: [dev] st lack of scrollback

2016-08-12 Thread Amer
Actually, it's no more than what you have called it, hack. It works only in bash -- due to it's policy of propagating HUP to childs when main process exits. So dash, etc. are out of question -- even by applying numerous nested dirty hacks. It makes me sad, being unable to compose clean solution.

Re: [dev] st lack of scrollback

2016-08-11 Thread Amer
Thanks for idea, but this option doesn't feet the purpose at all. It will always destroy any unattached session. Even on manual detach. And what now? Manually switch option each time before detach? Bind switching to 'd' key and hope it's robust enough solution? Moreover, what to do with global

Re: [dev] st lack of scrollback

2016-08-11 Thread Amer
For me it started playing nicely only with wrapper to tmux, though. Because I didn't liked how sessions stayed alive after killing terminals directly through window manager. $ st -e r.tmux $ cat r.tmux #!/bin/bash -e trap "tmux kill-session -t st-$$" INT TERM EXIT tmux new-session -s st-$$

Re: [dev] [st][PATCH] Use XftFontMatch in place of FcFontMatch.

2016-07-03 Thread Amer
Seems like I was able to narrow down the bug with fonts fallback. (Requisites: multiple fallback fonts for 'monospace'.) Running on HiDPI with 'pixelsize' -- all works as expected: st -f monospace:pixelsize=35 Using relative font size, only first font treats 'size' as relative. But all

Re: [dev] [st][PATCH] Use XftFontMatch in place of FcFontMatch.

2016-07-03 Thread Amer
correctly works for aforementioned problems. At least there is hope to highlight involved key points. On Fri, Jun 03, 2016 at 03:06:23PM +0200, Christoph Lohmann wrote: > Greetings. > > On Fri, 03 Jun 2016 15:06:23 +0200 Amer <amer...@gmail.com> wrote: > > st/config.def.h >

Re: [dev] [st][PATCH] Use XftFontMatch in place of FcFontMatch.

2016-05-27 Thread Amer
Hi Mark, After applying your patch, fontconfig fallbacks don't work for me anymore. Only first/main font is scaled, and all consequent aren't. st/config.def.h static char font[] = "monospace-9.6"; ~/.config/fontconfig/fonts.conf ... monospace Source

Re: [dev] [st] broken xft fallback with point size

2016-04-19 Thread Amer
> Supporting fallback fonts doesn't mean it supports passing comma > separated list of fonts as parameter (either command line or compile > time). Maybe if it's not mentioned in the man is because it doesn't > work that way. Thanks, my misunderstanding is cleared now. I applied the ideology used

Re: [dev] [st] broken xft fallback with point size

2016-04-19 Thread Amer
> Ask the person maintaining fontconfig. St uses FcNameParse() from > font‐ config in your case. Christoph Lohmann, thanks for directions. Earlier, I thought it was st-related problem, because it worked in dwm. Now I see that st does nothing to font string, passing to Fc. If I understood

[dev] [st] broken xft fallback with point size

2016-04-19 Thread Amer
Works $ st -f 'Inconsolata-12,DejaVu Sans Mono-12' $ st -f 'Inconsolata:pixelsize=15,DejaVu Sans Mono:pixelsize=15' Broken $ st -f 'Inconsolata:size=15,DejaVu Sans Mono:size=15' : st: can't open font Inconsolata:size=15,DejaVu Sans Mono:size=15 Is it a bug or the support for

Re: [dev] [st] no focus events inside tmux

2016-04-05 Thread Amer
On Tue, Apr 05, 2016 at 12:08:15AM +0200, k...@shike2.com wrote: Thanks for investigation, It's likely that tmux checks some specific terminfo properties before relaying 1004. If that's the case, we could temporarily override them inside .tmux.conf to confirm and then add to compiled st terminfo

Re: [dev] [st] no focus events inside tmux

2016-03-30 Thread Amer
On Wed, Mar 30, 2016 at 08:17:39AM +0200, k...@shike2.com wrote: Hi, I'm glad someone finally tried it.:) However, I wonder how you could receive this focus-in event: > $ printf "\e[?1004h" > ^[[I$ Because it don't work for me in dwm either. Let's make more detailed test case:

[dev] [st] no focus events inside tmux

2016-03-24 Thread Amer
Prerequisites: Tiling WM i3wm / xmonad -- not related to bug. And tmux has in tmux.conf set -g focus-events on Test case for bug: Open empty terminal st -e tmux Activate focusing printf "\e[?1004h" Catch one focus event Move focus to another window Expected: