早一陣子有朋友問起甚麼是集字作品,我新買的禮器碑集字帖有很詳盡的剖析:集字作品中的字有以下來源:
- 直接從原作取字
- 原作無該字,利用已知的邊旁寫法拼合而成
- 原作無該字亦無邊旁可參考,則從原作筆劃結構和筆意推論
以下是我最近臨的一些集字作品:
比較同一首詩用不同字體寫出來,味道各有不同,實是樂事!
For everyone who entered the real world around the 00 decade.
早一陣子有朋友問起甚麼是集字作品,我新買的禮器碑集字帖有很詳盡的剖析:集字作品中的字有以下來源:
以下是我最近臨的一些集字作品:
比較同一首詩用不同字體寫出來,味道各有不同,實是樂事!
npm install yarn yarn install yarn generate ./release/linux-unpacked/signal-desktop
今早一時興起搜尋一下永遇樂這個詞牌的名作,最有名的自然是辛棄疾的《京口北固亭懷古》(千古江山),李清照的《落日熔金》寫元宵亦是佳品,對我來說,back story最有趣的自然是東坡的《彭城夜宿燕子樓》,燕子樓曾是唐朝名歌妓關盼盼的居所,是關的情人、大官張愔為她所建。張愔死後,關盼盼一直獨居燕子樓,可見兩人感情之深。張的友人張仲素寫了以下的這首詩描述關對張愔思念之情:
樓上殘燈伴曉霜,獨眠人起合歡床。 相思一夜情多少,地角天涯未是長。
白居易則作此詩唱和:
滿床明月滿簾霜,被冷燈殘拂臥床。 燕子樓中霜月夜,秋來只為一人長。
(又有傳說指關盼盼後來自盡,皆因為讀了白居易此詩《感故張僕射諸妓》:
黃金不惜買蛾眉,揀得如花三四枝。歌舞教成心力盡,一朝身去不相隨。
不過已有不少學者網民為白平反,因為張僕射指的是張愔之父,詳情請參閱此文,有空會寫寫此故事)
蘇東坡作為一代文學宗匠,也是風流才子,留宿燕子樓自然夢到盼盼,醒後有感而發,作詞一首《永遇樂》(節錄):
天涯倦客,山中歸路,望斷故園心眼。燕子樓空,佳人何在,空鎖樓中燕。古今如夢,何曾夢覺,但有舊歡新怨。異時對,黃樓夜景,為余浩嘆。
感嘆世人在俗世浮沉,迷失於紅塵中,其實最終要認識到人生無常,一切只是過眼雲煙;蘇東坡時人會在燕子樓為關盼盼感嘆,而後人又會在黃樓為蘇東坡感嘆吧!
傳聞蘇東坡本人也有一位名盼盼的心愛歌妓,此女姓馬不姓關,坊間也流傳一個馬盼盼和黃樓的故事!話說蘇東坡被派往徐州做官,解決了洪水之災,為紀念此事及以「土尅水」,建了一座黃樓(此文有圖),其弟蘇轍作了一篇《黃樓賦》(原文)由也是大書法家的蘇東坡書寫後刻碑,東坡寫到一半走開了,頑皮的馬盼盼接著寫了「山川開闔」四字,原來她一直練習蘇體,寫得似模似樣,之後也被保留下來。
究竟那四字寫成怎樣?在網上完全找不到圖片,而原碑早已被毀,據報導政府在1988年重修,碑文也根據拓片重刻,希望有心的網友有機會看到拍張照片上傳過來吧。
(由書法字典集字而成) |
If you came here for the song, please go to YouTube. This is my one note for fixing my SAMBA-related issue on my Manjaro box. Basically gio mount gave me the following error:
Failed to mount Windows share: Software caused connection abort
Fortunately I found this post, in my case, I created a new smb.conf file as root and added the global protocol line to it.三個月前的今天剛裝了Elementary OS,可是陳年60GB HD那個partition已極速爆滿,是時候換新SSD,今次買的240GB比當年那個60GB還要便宜!
因為新鮮感已失,加上日本語輸入法使用甚不方便,所以打算「從新出發」,在新SSD上裝一個未用過的Linux Distro, 讀了好幾篇關於Linux Distro的文章,決定先試以前曾有不俗經驗的Arch Linux, 見有一個甚獲好評名為EndeavourOS的新Arch Linux-based Distro, 於是下載了ISO, 用dd抄了去USB手指,boot時到BIOS指定用USB即成,在Live env試了一會就裝,由於HD是全新,所以安裝沒有甚麼特別選擇,完成後reboot,循例update了所有packages, 然後再reboot就只有白紅藍全營幕輪流出現!再重裝一次又是如此。
為確定不是HD問題,於是用dd把舊HD複製到新HD,保留了原本所有boot records/partitions/OS, 可進入原來的Elementary OS了,再下一步是玩玩GParted: 複製後新HD有180GB左右的Unallocated space, 有甚麼方法加到Elementary OS那個爆滿的Partition呢?首先,我消滅了兩者之間的小小swap partition,原來還要把這個Unallocated space「撥入」Elementary OS那個Partition的parent才可以resize, reboot時GRUB就找不到Boot record了,看了此文,估計名字變動了,即管試試set prefix,果然全中!於是update-grub and grub-install. 有了可用的installation,又再心癢試新事物,今次是另一個Arch Linux based Distro: Manjaro, 難題是要和Elementary OS的Partition共存,所以徵用那個已廢的Ubuntu partition,不過Installer認為無free space而安裝失敗,於是我再用GParted把那個partition recreated, 今次Manjaro installer沒問題了。
裝好Manjaro之後,為證明比Elementary OS優勝,「試題」是再裝倉頡日本語一較高下。「解題」用了四個小時,不過「答案」的確更好。閒話少講,關鍵是跟此君要用pamac安裝ibus, ibus-table-chinese, ibus-mozc(這個需要在機上build, 失敗了三次才成功,浪費了不少時間)然後setup IBUS加Japanese-MOZC, Chinese-Cangjie3 最後一步是找個file to force autostart, 又找了好一會,答案是:
cat .xprofile export GTK_IM_MODULE=ibus export XMODIFIERS=@im=ibus export QT_IM_MODULE=ibus ibus-daemon -drx
各位網友晚安!
後記:分享一個師兄教路在Xfce "Dock"加App的方法(其實是他舉出Xfce如何難用的例子)
I wrote about using Mac OS X Automator for converting a PDF to images. How about Linux? I found this solution: At command line, execute
pdftoppm -jpeg <pdf file name> <prefix of jpg files to be created>
It might be already installed in your Linux box. If not, it is part of poppler-util.
The title mentions both Linux and Mac and that's not a typo: I have a requirement to record my screen on my Linux box and then put that video into iMovie on Mac for editing. (Yes, I could have used a Linux video editor but that's a different story)
I installed a simple screencasting tool called Kazam on my Linux box, record and save the movie in H264 format, which is the same encoding as QuickTime (Mac)
However, QuickTime refused to open my file! It turns out the pixel format is the culprit:
ffmpeg -i 'Screencast 2020-09-03 13:59:50.mp4' -pix_fmt yuv420p -f mov output.mov
defaults write com.apple.finder CreateDesktop false killall Finder
defaults write com.apple.finder CreateDesktop true killall Finder
昨天和老同學討論Mac vs Windows, 當然火花十足,事實上我也算不上蘋果忠粉,用的日子也不長,所以至今天才發現Automator這個「新」功能,今天要和各位網友分享。
話說我製作蘇子曰YouTube頻道的錄像時,在資料搜集期間,用Google Slides最為方便,不過錄影時如果要同時控制Presentation的話難免分心,所以會在錄影完畢後,在iMovies的Main track逐張Slide的圖像加上去,再在Main Track之上加上有「 人頭」的部份作Picture-in-picture.
問題來了:在Google Slides入面只能逐個Slide「手動」Export為圖像檔!如果多Slides的話頗費時。其他可Export的格式包括PowerPoint及PDF等,而這些格式又能否「一次過」轉為多張圖像呢?答案是可以的!特別鳴謝兩位網友(Link1, Link2)
我在此簡單描述一下步驟:
Back in the days most of us (with some tech backgrounds) have played with creating a personal website by writing our own HTML that has our bio and some pictures embedded. And most of us used free web hosting (why pay for it anyway? :P) Then FB got popular and the rest is history. Fast forward 2 decades and the most popular free "site builders" like Wix and Google don't serve raw HTML page you write anymore, which is understandable because it's harder to secure things they don't control. Long story short, I needed to serve a page, and using the HTTPS protocol. And InfinityFree came to rescue!
I created a new (free) account and provided it a domain name I purchased from GoDaddy years ago (for fun and good luck mainly :P) By doing so I needed to change the namesever records to point to the ones used by InfinityFree/Epizy. Then I clicked on the "Free SSL certificates tab" which listed 4 steps:
1. Add CNAME records (which is done on the InfinityFree/Epizy side because of the nameserver change) This took a few hours to become effective.
2. Request a new (free) SSL cert. Not sure how long it took between request and issue.
3. Install the new cert. This is done via copy-and-paste the key and the cert under the SSL/TLS in cPanel.
4. Check for validity of your cert. You can use SSLShopper.com and simply type in your www.<domain name>
Any html you want it to serve can be uploaded via FTP or File Manager under the htdocs dir. For those who used Apache back in the days of course knows about htdocs. Nginx use the same dir too. The good thing is InfinityFree/Epizy created a new user for such purpose that is separated from your InfinityFree logon.
The only downside of free SSL cert is that it usually expires soon. I setup reminder on the InfinityFree side for renewal. Let's see if that works. Anyway, I think it has done a good job already for such free services.
As I mentioned in this post, I found that Cursive IDE is the recommended way to go and that's what I tried. To be honest, the whole process is not exactly what I would call intuitive. I think the guides I mentioned in my previous post did a pretty good job. Let me summarize a few key features:
1) CursiveIDE is based on IntelliJ so the latter is the one you start. The type of project to add is Clojure->Leiningen (FYI, Leiningen is a build automation tool. I think the name comes from the short story "Leiningen Versus the Ants" Of course, ant refers to the "other" famous tool)
The project name must be all lowercase.
The IDE automatically creates a bunch of files for you. The most important one is probably project.clj. If your code requires importing external modules, you specify the dependency in this file. I found that the REPL that is already running would not "take in" the new dependency so the safest thing to do is to kill the existing REPL and start a new one.
2) The Right-click menu of project.clj has a choice to start your REPL. By default the namespace is <your project name>.core. In fact, Cursive also automatically creates a core.clj file for you.
3) If you want to have code in another <file name>.clj file, you add New Clojure Namespace with <file name>, the namespace would be <project name>.<file name>
4) You can load your current .clj file into the REPL using the right-click menu and then REPL.
5) However, Cursive does not switch namespace automatically. Use the same menu to switch.
6) You can send a statement in your .clj file to the REPL for execution. Alternatively you can type the statement in the lower REPL window and hit ENTER after the closing ')' (or hit CTRL-ENTER)
BTW, this is the fun project I worked on: calculation of hours of sunlight based on the coordinates of the city and the date.
最近在玩師兄介紹的Elementary OS,他亦推薦其中一張寫著中文書法「停雲館」的Wallpaper,引發了一場關於「停雲」的討論。
首先找到的是辛棄疾詞《賀新郎·甚矣吾衰矣》,其中有一句:
一尊搔首東窗里。想淵明《停雲》詩就,此時風味。
詞中更出名那一句是:
我見青山多嫵媚,料青山見我應如是。
照字面解作詞人顯得相當有自信,其實根據上文下理自嘲成份較重。全詞充滿抗金壯志未能酬,志同道合之士日少的感慨。根據詞序,辛棄疾作詞時正獨坐於一個叫「停雲」的堂館,而停雲也是陶淵明一首詩的名稱,以下摘自網上文章:
《停雲》是晉宋之際詩人陶淵明的作品。此詩分四章,其主旨正如序中所言,“思親友也。”詩中運用比興的手法和覆沓的章法,通過對自然環境的烘托描寫,和不能與好友飲酒暢談的感慨,充分抒发了詩人對好友的深切思念之情。同時,詩中“八表同昏”“平路伊阻”“平陸成江”等詩句也暗含了作者對時世的擔憂。
可見情感和辛棄疾想表達的相當類似。之後辛棄疾亦諷刺當時想在酒中求名的文人(蘇東坡乎?)辛認為酒的真正「功能」是解愁罷了。
元人散曲中,還有集各種專名者。如孫季昌的《端正好》套集雜劇名詠情,王仲元的《粉蝶兒》套集曲調名題秋怨,孫叔順的《粉蝶兒》套集藥名等即是。這其中,有時也頗有巧思,應當算是一種藝術,有時候在文藝之外,也還能起到一些意外想不到的作用。如日本青木正兒的《元人雜劇序說》,就曾利用孫季昌那首集雜劇名的散套,考證某些雜劇的時代。日本人寫的《宋元科技史》,也曾引用到孫叔順的集藥名散曲。以《粉蝶兒》之五《石榴花》為例:
常記得《賞花時》節《看花回》,《上京馬》《醉扶歸》。《歸來》窗半《月兒低》,真個《醉矣》。《柳青娘》《虞美人》扶只,困騰騰《上馬嬌》無力,《步步嬌》弄影兒行遲。似《鳳鸞》交配答《雙鴛鴦》對,人都道《端正好》夫妻。
我的心有如暗黑的夜
當樹頂沙沙作響
月亮平靜地從雲中升起大放光芒,看看!
樹林靜了下來聆聽
你是月亮,閃閃生光的月亮
你用滿滿愛意
向我拋個媚眼
當中滿載天堂般的平安感,看看!
我如暴風雨的心已被安撫
爛柯山下舊仙郎,列宿來添婺女光。遠放歌聲分白紵,知傳家學與青箱。
水朝滄海何時去,蘭在幽林亦自芳。聞說天台有遺愛,人將琪樹比甘棠。
衢州徐員外使君(未知此人是誰,當是劉禹錫的朋友吧)將縞紵和一箱竹書贈與我故而寫此篇用作回贈 (佳貺:好的贈品)於是知道原來爛柯山就在衢州,中國圍棋友都應該聽過和爛柯山有關的神仙下棋典故吧!這位網友去過拍了很多照片。我也想起金庸小說《碧血劍》應該有提過衢州,那是主角袁承志「仇家/親家」(溫青青五位公公和母親)棋仙派所在地(去年寫過相關的帖)
爛柯山下住著您這位如神仙一般的世外高人,就連天上的星宿也要為你來增添光彩.你豪邁奔放縱聲高歌那衣袖也要起舞翩翩,你的學識留在這書箱之內流傳後世.世俗紅塵就讓他們隨波逐流慢慢遠去吧,如果自己品德高尚在什麼時候都會放光.聽說在天台治理有方,很受百姓愛戴,你辛勤王事,竟然不把仙界的玉樹當一回事,只在樹下辛勞理政
衢州江上別李秀才上月本人離開家鄉,正值武肺肆虐,心情相類。
【唐】韋莊
千山紅樹萬山雲,
把酒相看日又曛。
一曲離歌兩行淚,
更知何地再逢君。