feat(term size): add max-font-size mode 新增最大字型大小模式 #81
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The
max-font-size
mode behaviors like thefixed-font-size
mode in that a basic font size can be specified by the user.max-font-size
(最大字型大小)模式很類似於fixed-font-size
(固定字型大小)模式,它們的基本字型大小都可由使用者指定。However, when the window is too narrow or too short,
fixed-font-size
just lets the terminal screen overflow the window, whilemax-font-size
shrinks the font to keep the screen inside the window.但,當視窗過窄或過矮,
fixed-font-size
(固定字型大小)會直接讓終端機畫面超出視窗,而max-font-size
(最大字型大小)會縮小字體讓畫面維持在視窗內。This feature should benefit users who use PttChrome on a relatively small screen (e.g., mobile/tablet users) and want to maximize the use of the limited space of their screen for reading without manually tweaking the terminal size in the
fixed-term-size
mode.這個功能應有利於在相對小的螢幕(例如手機或平板電腦)上使用 PttChrome,且想儘量利用閱讀時有限的螢幕空間,又不想手動調整
fixed-term-size
(固定終端機大小)中的終端機寬高設定的使用者。Video for demonstration 展示影片:
DreamBBS-v3.0.2021-04-27.pttchrome.max-font-size.resizing.mp4
Note: After the recording of the video, the options for specifying the minimum height and width of the terminal screen size for
max-font-size
were dropped for the convenience of user. The minimum terminal screen size is hardcoded as 80 cols x 24 rows.注意:在錄完該影片後,爲了方便使用者,移除了
max-font-size
(最大字型大小)中用來指定終端機的最小高度與寬度的選項。終端機的最小寬高寫死成 80 縱列 × 24 橫行。