欢迎光临散文网 会员登陆 & 注册

小狼毫輸入法皮膚加陰影

2023-08-15 17:41 作者:有電  | 我要投稿

     2023年6月6日,小狼毫輸入法更新到 0.15.0 版。這個新版支持候選窗加陰影,好久不折騰輸入法的我,又搞了一下!

     
    皮膚名稱: "冷漠 / Apathy"

    作者: "LIANG Hai "
參攷這個皮膚,在綫網頁「潤筆 - Rime設置小助手」那裡微調一下,在【小狼毫】更新日誌裡內容找到陰影相關代碼。

    不加陰影的樣子,設置候選窗邊框寬度爲 2
      style/layout/border_width: 2

加上陰影的樣子

weasel.custom.yaml
----------------------------------------------------------------

customization:

  distribution_code_name: Weasel

  distribution_version: 0.15.0.0

  generator: "Weasel::UIStyleSettings"

  modified_time: "Wed Aug  9 01:45:38 2023"

  rime_version: 1.8.5

patch:

  style/color_scheme: Bluewhite

  style/layout/border_width: 0

  style/layout/min_width: 120

  style/layout/corner_radius: 8 # 候选框外窗口圆角半径

  style/layout/shadow_radius: 10 #全局阴影模糊半径,如果为0则全局禁用阴影

  style/layout/shadow_offset_x: 3 # 阴影x偏置,正向右负向左

  style/layout/shadow_offset_y: 3 # 阴影y偏置,如果x,y都是0,而shadow_radius不为0,则四周绘制阴影;否则drowshadow阴影

  

  preset_color_schemes:

    Bluewhite:

      name: 蓝白色/Bluewhite

      author: 偶得

      text_color: 6908274

      back_color: 16777215

      border_color: 15592943

      label_color: 6647406

      hilited_text_color: 12549671

      hilited_back_color: 15128762

      candidate_text_color: 0

      comment_text_color: 11316396

      hilited_candidate_text_color: 14512933

      hilited_comment_text_color: 9870235

      hilited_candidate_back_color: 16773338

      hilited_label_color: 14653283

      

      shadow_color: 0x4ccdcdcd #阴影颜色

------------------------------------------------------------
有些候選窗元素放在輸入法設置文本裡,隨便給出代碼,要掛鄭碼的可以參攷一下。
zishu.schema.yaml
--------------------------------------------

# zishu schema

# encoding:utf-8


schema:

  schema_id: zishu

  name: 正碼

  version: "1.0"

  author:

    - 繁體鄭碼

  description: |

    - “偶得” 調整簡碼部分

  dependencies:

    - pinyin_simp


switches:

  - name: ascii_code

    reset: 0

    states: [ 中文, 西文 ]

  - name: full_shape

    states: [ 半角, 全角 ]

  - name: ascii_punct

    states: ["句讀", "符號"]

  - name: simplification

    states: [ 漢字, 汉字 ]

  - name: extended_charset

    states: [ 通用, 增廣 ]

    

engine:

  processors:

    - ascii_composer

    - recognizer

    - key_binder

    - speller

    - punctuator

    - selector

    - navigator

    - express_editor

  segmentors:

    - ascii_segmentor

    - matcher

    - abc_segmentor

    - punct_segmentor

    - fallback_segmentor

  translators:

    - punct_translator

    - reverse_lookup_translator

    - table_translator

  filters:

    - reverse_lookup_filter@zishu_reverse

    

speller:

  alphabet: zyxwvutsrqponmlkjihgfedcba`

  delimiter: "`"

  max_code_length: 4

## ▲最大码长 

  auto_select: true

## ▲自动上屏 

  auto_clear: auto

#  ▲manual/auto/max_length 空码按下一键确认清屏/空码自动清/达到最长码时后码顶上清屏

    

translator:

  dictionary: zishu

  enable_charset_filter: true

  enable_sentence: false #關閉碼表輸入法連打

  enable_encoder: false

  encode_commit_history: false

  enable_completion: true

  enable_user_dict: false #關閉用戶詞典和字頻調整

  comment_format:

    - 'xlit/~/ /' #去掉编码提示前的波浪号~

  


reverse_lookup:

  dictionary: luna_pinyin

  prefix: "`"

  suffix: "'"

  tips: 〔拼音〕

  preedit_format:

    - xform/([nl])v/$1ü/

    - xform/([nl])ue/$1üe/

    - xform/([jqxy])v/$1u/


zishu_reverse:

  dictionary: zishu 

  overwrite_comment: false

  comment_format:

    - xform/^/  [/

    - xform/$/]/



punctuator:

  import_preset: default

  full_shape:

    "/" : "、"

  half_shape:

    "/" : "、"


key_binder:

  import_preset: default

  bindings:

    - {when: has_menu, accept: space, send: space}

    - {when: composing, accept: Return, send: Escape}

    - { when: has_menu, accept: semicolon, send: 2 }

    - { when: has_menu, accept: apostrophe, send: 3 }

# ▲应用以回車清除編碼串, “;”选二重,“‘”选三重 


recognizer:

  import_preset: default

  patterns:

    reverse_lookup: "^`[a-z]*'?$"

    

menu:

  page_size: 3

  alternative_select_labels: [ ①, ②, ③, ④, ⑤, ⑥, ⑦, ⑧, ⑨ ]  # 修改候選標籤

style:

  font_point: 13

  horizontal: true #横排显示

  line_spacing: 1 #行距

  inline_preedit: true # 嵌入式候选窗单行显示

  label_format: '%s' #去掉候选词和序号之间的点号

--------------------------------------------------------------------------


小狼毫輸入法皮膚加陰影的评论 (共 条)

分享到微博请遵守国家法律