| adm | Find | login register |
eliu joined: 2007-08-09 posted: 11474 promoted: 617 bookmarked: 187 新竹, 台灣 |
| |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
| |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
| |||||||||||
winlin joined: 2007-09-25 posted: 1859 promoted: 111 bookmarked: 33 |
感謝T大: ------------------------------------------------------------------- | |||||||||||
eliu joined: 2007-08-09 posted: 11474 promoted: 617 bookmarked: 187 新竹, 台灣 |
所以你們覺得是要用 button 還是 event_box,button 比較漂亮,但是比較佔空間。 感謝 Tetralet 鍥而不捨的追查,gcin 還有很多地方用 event_box,只能說 GTK 的 default value 太爛了。 | |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
event_box++ button 說真的醜到爆,醜到我連 deb 都不想包... XDDDD 另外可能要請 eliu 在所有 gtk_event_box_new() 後面都加上那一行 patch, | |||||||||||
winlin joined: 2007-09-25 posted: 1859 promoted: 111 bookmarked: 33 |
小弟投「button」一票 XD (不知會否破壞小弟和T大的關係...) 小弟有一票的理由,晚一點再提,不然這一篇會寫得太長~ 小弟發現button還有一個inner-border的屬性可以設,
參考資料:http://developer.gnome.org/gtk/2.24/GtkButton.html
醜到不想包!!!??? 請陛下三思呀~ button好看與否,和gtk主題的button設計有關
下載一個button好看的gtk theme,然後.... pkill gcin; export GTK2_RC_FILES=/放置路徑/gtk-2.0/gtkrc; gcin & ------------------------------------------------------------------- | |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
個人是覺得真的醜斃了。 | |||||||||||
winlin joined: 2007-09-25 posted: 1859 promoted: 111 bookmarked: 33 |
eliu兄: 在gcin source code裡指定button的inner border應該是可行的 我在~/.gtkrc-2.0加入下面這段陳述並重新啟動gcin之後,發現button的inner border的確有縮小一些, style "button"
這張圖是套用這個設定值之前: 這張圖是套用這個設定值之後: 小弟個人還是比較希望用button, 如果可以克服border的問題,不但比較沒有T大在意的版面問題,又可以兼顧美感,算是一舉兩得。 感謝~ ------------------------------------------------------------------- | |||||||||||
winlin joined: 2007-09-25 posted: 1859 promoted: 111 bookmarked: 33 |
啊...上一篇發文已經來不及了......
------------------------------------------------------------------- | |||||||||||
caleb joined: 2007-09-22 posted: 630 promoted: 134 bookmarked: 90 |
查了 gtk2 API, button 的 inner-border 似乎只能 read,也就是無法在程式內部指定,只能用 gtkrc* 設定。 gtk3 才可以在程式內部指定。 | |||||||||||
caleb joined: 2007-09-22 posted: 630 promoted: 134 bookmarked: 90 |
唔,查了查有個 gtk_widget_modify_style(button, rcstyle); 可以設定 rcstyle->xthickness = 0; 不確定是不是和設定 inner-border 一樣… | |||||||||||
winlin joined: 2007-09-25 posted: 1859 promoted: 111 bookmarked: 33 |
不知道能否換個方式,讓gcin內帶一個gtkrc呢?theme的內容就只寫:
style "button"
不過,如果只有這4行陳述,gcin會跟隨使用者的gtk佈景主題,只針對button inner border作調整? 這要試試看才知道 ------------------------------------------------------------------- | |||||||||||
eliu joined: 2007-08-09 posted: 11474 promoted: 617 bookmarked: 187 新竹, 台灣 |
2.4.1 | |||||||||||
winlin joined: 2007-09-25 posted: 1859 promoted: 111 bookmarked: 33 |
感謝caleb兄提示!!!小弟終於找到button border的2個相關參數所在!
上述2個參數設成0之後,button也可以和event_box完全一樣的大小,不多佔任何空間!!! 在主題中的gtkrc中設好下列參數即可測試: style "button" xthickness = 0 以下是小弟各種組合的測試結果圖示,可以看到詞音和用button的gtab可以設成和event_box完全一樣的比例。 ------------------------------------------------------------------- | |||||||||||
eliu joined: 2007-08-09 posted: 11474 promoted: 617 bookmarked: 187 新竹, 台灣 |
| |||||||||||
eliu joined: 2007-08-09 posted: 11474 promoted: 617 bookmarked: 187 新竹, 台灣 |
找到方法可以設定了 2.4.2 - gtab window 現在內定改成 button 了,而且找到設定 inner border 的方法,所以 button 比較小了。詞音的注音輸入區字型可以 +4 點,否則 Window 的高度會變成忽大忽小。
| |||||||||||
eliu joined: 2007-08-09 posted: 11474 promoted: 617 bookmarked: 187 新竹, 台灣 |
| |||||||||||
winlin joined: 2007-09-25 posted: 1859 promoted: 111 bookmarked: 33 |
eliu兄辛苦了,為了button的事讓您一改再改真不好意思~ ------------------------------------------------------------------- | |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
先送上 patch。之前的修改沒考慮到『沒有隱藏第二列』的狀況。 另外,這是我的 GCIN 使用 echo 1 > ~/.gcin/config/gtab-in-area-button 後的貼圖: 以下是調整成個人的使用習慣: 而以下是不使用 button 的狀況: 何謂美醜雖然是一種主觀看法, | |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
以下為一些後續的修正。 gcin_1.diff: gcin_2.diff: gcin_3.diff: gcin_4.diff: gcin_5.diff: gcin_6.diff: 請劉老大考慮套用這些 patch。謝謝! | |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
另外回報一個問題,好像沒辨法把【五四三】倉頡取消掉? | |||||||||||
eliu joined: 2007-08-09 posted: 11474 promoted: 617 bookmarked: 187 新竹, 台灣 |
你是用 cj5?cj5 & 五四三倉頡是共用 同一個 key,五四三倉頡不要勾選「使用」,就不會 load 進來,也就不可能在循環裏面? | |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
個人是建議分開啦。 | |||||||||||
eliu joined: 2007-08-09 posted: 11474 promoted: 617 bookmarked: 187 新竹, 台灣 |
edited: 1
| |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
不是,是勾了倉五,沒勾倉五四三, | |||||||||||
eliu joined: 2007-08-09 posted: 11474 promoted: 617 bookmarked: 187 新竹, 台灣 |
| |||||||||||
Tetralet joined: 2007-11-27 posted: 255 promoted: 35 bookmarked: 13 |
一些小問題的修正。 若無意外,這應該會是最後一個 patch 了, |
| adm | Find | login register |