XFCE (Xubuntu) 下的手動 lock + screensaver + DPMS 組合

桌機換成 Xubuntu 22.04 後會遇到手動鎖定螢幕時,螢幕不會進入省電模式,遇到的情況有點像是「DPMS Suspend on Screen Lock」這邊提到的情境。

這類問題如果用 search engine 一時間沒有找到解法的話,最好的方法都是直接去讀 source code,然後就發現透過 Ctrl+Alt+L 觸發的 /usr/bin/xflock4 其實是個 shell script,從 code 讀可以發現裡面只負責 lock 的部分,本來就跟 DPMS 無關。

我在下面提供的方案就是自己處理螢幕的部分,也就是自己先跑 DPMS 指令,然後再回頭呼叫 /usr/bin/xflock4

#!/bin/sh
/usr/bin/xset dpms force off
exec /usr/bin/xflock4

Ctrl+Alt+L 的觸發程式掛上來,這樣就會正常處理了...

在非 4K 的螢幕上跑 HiDPI

前幾天看到 BetterDummy 這個專案,作者在 M1 上面外接 24" 1440p 的螢幕,但沒辦法啟用 HiDPI,於是就寫了一個軟體來解:

M1 macs tend to have issues with custom resolutions. Notoriously they don't allow sub-4K resolution displays to have HiDPI ("Retina") resolutions even though (for example) a 24" QHD 1440p display would greatly benefit from having an 1920x1080 HiDPI "Retina" mode.

在這之前的解法都有些麻煩,一種是買個 dummy dongle 去騙 macOS,另外是用 mirror 的方式使用:

To fix this issue, some resort to buying a 4K HDMI dummy dongle to fool macOS into thinking that a 4K display is connected and then mirror the contents of this dummy display to their actual monitor in order to have HiDPI resolutions available. Others use the built in screens of their MacBooks to mirror to the external display. These approaches have obvious drawbacks and cannot solve all problems.

作者提供的軟體可以先建立 Dummy Monitor,然後再透過 mirror 掛到實際螢幕上:

不確定用起來如何,但如果之後有需要的話好像可以測試看看...

4px 寬的字型

也是在 Hacker News Daily 上看到的:「a pretty sweet 4px wide pixel font.」,看 commit log 似乎很久了,字本身長這樣:

作者有提到可以用在解析度不夠的螢幕上,馬上想到的是「Waveshare 3.2 inch Raspberry Pi LCD 320X240 Resistive Touch Screen TFT Display SPI LCD for Raspberry Pi 3 Model B/3B+/2 B/B/A Raspbian IMG Provided」這種東西:

另外用在小顆 LCD 單色顯示似乎也是個方法,不過看了一下是 5px:

出自「Real Time Clock On 20x4 I2C LCD Display with Arduino - Electronics-Lab.com」。

先記起來...

超高 PPI 的螢幕

看到「DPI Calculator / PPI Calculator」這個網站,裡面有一些有趣的小螢幕,但是有超高解析度:

1280x1024 @ 0.61 MicroOLED microdisplay (2687.21 PPI)
1920x1080 @ 0.74 Silicon Micro Display ST1080 (2976.9 PPI)
2048x1536 @ 0.83 Forth Dimension QXGA-R9 (3084.34 PPI)
2048x2048 @ 0.99 Kopin Lightning 2K (2925.57 PPI)

不過如果放寬到只要是螢幕就可以的話 (不用是彩色的),查了一下發現跟目前的進展有點遠,目前有查到的是 14000 DPI:「14,000ppi MicroLED display is world’s densest, only 0.48mm across」:

According Mojo Vision, with a world record pixel pitch of 1.8µm and a pixel density over 14,000ppi, the monochrome display technology is the company’s first important step in succeeding in its mission to deliver “Invisible Computing”, enabling people to receive and share information that is immediate and relevant without distracting them from the world in front of them.

不過考慮到彩色螢幕需要三色,上面那幾個 3000 PPI 好像已經很厲害了...

Twitter 連名字描述的部份也加長了...

Twitter 這陣子最有明得應該是 140 chars -> 280 chars,不過有媒體發現名字描述的長度也提昇了:「Twitter now lets your display name be longer too – up to 50 characters」。

You were previously limited to 20 characters, but now you have 50 to work with.

之後可以有更多奇怪的花樣了 XD

外接 iPad Retina 面板當螢幕用...

LGLP097QX1-SPA1 有被蘋果拿去當 iPad Retina 的顯示面板,但也有零賣... 於是就有人在 eBay 上面買了一張改裝:「Connecting an iPad retina LCD to a PC」。

在 eBay 買 USD$55,再把其他零件成本一起算進來,全部也才 USD$70... 是個 2048x1536 的高解析度螢幕 XDDD

下面這兩張的效果真不錯 XD