Man page - inkscape(1)

Packages contains this manual

Available languages:

en fr ko hu hr zh_TW de

Manual

INKSCAPE

名 稱
概 要
描 述
選 項
組 態 設 定
診 斷
範 例
環 境 變 數
其 他 資 訊
參 見
GUI 說 明
按 鍵 對 應
程 式 錯 誤
歷 史
作 者
著 作 權 和 許 可 證

名 稱

Inkscape - SVG (Scalable Vector Graphics) 編 輯 程 式 。

概 要

"inkscape [選 項 ] [檔 名 _1 檔 名 _2 ...]"

選 項 :

-?, --help
--help-all
--help-gapplication
--help-gtk
-V, --version
--debug-info
--system-data-directory
--user-data-directory
-p, --pipe
-n, --pages=PAGE[,PAGE]
--pdf-poppler
--convert-dpi-method=METHOD
--no-convert-text-baseline-spacing
-o, --export-filename=檔 名
--export-overwrite
--export-type=類 型 [,類 型 ]*
--export-extension=擴 充 模 組 識 別 碼
-C, --export-area-page
-D, --export-area-drawing
-a, --export-area=x0:y0:x1:y1
--export-area-snap
-d, --export-dpi=DPI
-w, --export-width=寬 度
-h, --export-height=高 度
--export-margin=間 距
--export-page=all|n[,a-b]
-i, --export-id=OBJECT-ID[;OBJECT-ID]*
-j, --export-id-only
-l, --export-plain-svg
--export-png-color-mode=COLORMODE
--export-png-use-dithering=BOOLEAN
--export-ps-level=LEVEL
--export-pdf-version=VERSION
-T, --export-text-to-path
--export-latex
--export-ignore-filters
-t, --export-use-hints
-b, --export-background=COLOR
-y, --export-background-opacity=VALUE
-I, --query-id=物 件 識 別 碼 [,物 件 識 別 碼 ]*
-S, --query-all
-X, --query-x
-Y, --query-y
-W, --query-width
-H, --query-height
--vacuum-defs
--select=OBJECT-ID[,OBJECT-ID]*
--actions=ACTION(:ARG)[;ACTION(:ARG)]*
--action-list
--actions-file=FILENAME
-g, --with-gui
-q, --active-window
--display=DISPLAY
--app-id-tag=TAG
--batch-process
--shell

描 述

Inkscape 是 一 款 自 由 與 開 放 原 始 碼 的 向 量 繪 圖 軟 體 。 提 供 強 大 豐 富 的 功 能 且 能 廣 泛 應 用 在 藝 術 與 技 術 用 途 插 畫 , 諸 如 卡 通 、 素 材 、 圖 標 、 設 計 原 型 、 圖 表 和 流 程 圖 。 使 用 向 量 圖 形 能 構 允 許 銳 邊 圖 像 輸 出 和 無 解 析 度 限 制 的 圖 形 繪 算 , 而 不 會 向 點 陣 圖 像 有 固 定 像 素 數 量 的 限 制 。 Inkscape 使 用 標 準 的 SVG 檔 案 格 式 昨 為 主 要 格 式 , 其 他 許 多 應 用 程 式 包 括 網 頁 瀏 覽 程 式 都 支 援 此 種 格 式 。

使 用 者 介 面 以 簡 單 易 用 且 能 讓 專 業 人 士 有 效 率 創 作 的 方 向 設 計 , 保 留 GNOME 桌 面 標 準 的 舒 適 性 以 確 保 使 用 者 能 以 其 他 GNOME 應 用 程 式 使 用 體 驗 快 速 學 習 操 作 方 式 。

SVG 是 W3C 針 對 2D 向 量 繪 圖 制 定 的 標 準 XML 格 式 。 SVG 可 於 圖 畫 中 使 用 點 、 路 徑 和 基 本 形 狀 來 定 義 物 件 。 顏 色 、 字 型 、 邊 框 寬 度 ...等 等 可 作 為 「 樣 式 」 屬 性 指 定 給 這 些 物 件 。 由 於 SVG 的 目 標 是 成 為 標 準 格 式 , 也 因 為 SVG 檔 為 純 文 字 檔 /xml, 所 以 有 相 當 多 的 程 式 可 能 使 用 SVG 檔 並 有 多 種 用 途 。

Inkscape 使 用 SVG 作 為 內 定 文 件 格 式 , 並 且 以 成 為 在 開 放 原 碼 社 群 中 完 整 相 容 SVG 格 式 的 繪 圖 程 式 為 目 標 。

選 項

-? , --help

顯 示 說 明 訊 息 。

--help-all

Shows all help options.

--help-gapplication

Shows the GApplication options.

--help-gtk

Shows the GTK+ options.

-V , --version

顯 示 Inkscape 版 本 和 編 譯 日 期 。

--debug-info

印 出 技 術 資 訊 包 括 Inkscape 版 本 、 相 依 套 件 版 本 和 操 作 系 統 。 此 資 訊 在 Inkscape 除 錯 的 時 候 非 常 有 用 且 應 該 將 資 訊 撰 寫 在 程 式 錯 誤 (bug) 回 報 中 。

--system-data-directory

印 出 系 統 資 料 目 錄 即 與 Inkscape 連 動 的 資 料 檔 案 儲 存 位 置 。 這 包 括 執 行 Inkscape 必 須 的 檔 案 (像 單 位 定 義 、 內 建 按 鍵 對 應 、 檔 案 描 述 UI 排 版 、 圖 示 主 題 等 等 )、 核 心 擴 充 模 組 、 常 備 資 源 (濾 鏡 、 字 型 、 記 號 、 調 色 盤 、 符 號 、 範 本 ) 和 文 件 (SVG 範 例 檔 案 、 指 導 手 冊 )。

Inkscape 預 期 的 系 統 資 料 目 錄 位 置 可 用 INKSCAPE_DATADIR 環 境 變 數 覆 蓋 。

--user-data-directory

印 出 使 用 者 設 定 檔 的 目 錄 即 使 用 者 指 定 的 資 料 檔 案 和 偏 好 設 定 的 儲 存 位 置 。 自 訂 擴 充 模 組 和 資 源 (濾 鏡 、 字 型 、 記 號 、 調 色 版 、 符 號 、 範 本 ) 應 該 安 裝 到 該 目 錄 底 下 的 各 自 子 目 錄 中 。 另 外 將 檔 案 以 系 統 資 料 目 錄 中 檔 案 的 完 全 相 同 名 稱 儲 存 可 覆 蓋 原 本 系 統 資 料 庫 的 大 部 分 預 先 設 定 (例 如 預 設 範 本 、 UI 檔 案 等 等 )。

設 定 檔 目 錄 的 預 設 位 置 可 用 INKSCAPE_PROFILE_DIR 環 境 變 數 覆 蓋 。

-p , --pipe

從 標 準 輸 入 (stdin) 讀 取 輸 入 檔 案 。

--pages = PAGE

Imports the given comma separated list of pages from a PDF, or multi page SVG file.

This replaces the --pdf-page from previous Inkscape versions.

--pdf-poppler

Inkscape 預 設 經 由 內 部 (poppler-derived) 函 數 庫 匯 入 PDF 檔 案 。 文 字 會 以 文 字 格 式 儲 存 。 使 用 --pdf-poppler 可 改 用 外 部 (使 用 cairo 後 端 的 poppler) 函 式 庫 匯 入 PDF。 文 字 組 成 包 含 複 製 的 字 (glyphs) 而 每 個 字 (glyphs) 都 是 路 徑 。 影 像 儲 存 在 檔 案 內 部 。 網 面 會 讓 整 份 文 件 都 以 點 陣 圖 形 方 式 繪 算 。

--convert-dpi-method = 方 式

選 擇 用 於 縮 放 舊 版 (pre-0.92) 檔 案 的 方 式 其 繪 算 稍 微 較 小 , 因 為 像 素 單 位 的 內 插 長 度 從 90 DPI 切 換 為 96 DPI。 數 值 可 以 設 定 為 「 none」 (不 變 更 、 文 件 繪 算 原 始 大 小 的 94%)、 「 scale-viewbox」 (文 建 會 整 體 縮 放 , 而 個 別 長 度 維 持 不 變 ) 和 「 scale-document」 (每 個 長 度 會 個 別 重 新 縮 放 )。

--no-convert-text-baseline-spacing

開 啟 舊 版 (pre-0.92) 檔 案 時 不 要 自 動 修 正 文 字 基 準 線 。 Inkscape 0.92 的 「 line-height」 性 質 採 用 CSS 標 準 定 義 , 這 與 之 前 的 版 本 不 同 。 預 設 文 字 列 高 度 值 以 檔 案 內 建 立 的 數 值 優 先 而 Inkscape 0.92 調 整 為 載 入 時 保 留 文 字 排 版 的 傾 向 。 此 指 令 選 項 則 會 跳 過 調 整 動 作 。

-o , --export-filename = 檔 名

設 定 輸 出 檔 案 的 名 稱 。 預 設 會 沿 用 輸 入 檔 案 的 名 稱 。 如 果 有 使 用 --export-type 選 項 , 那 麼 檔 案 副 檔 名 要 依 照 情 形 調 整 (或 加 入 )。 反 之 匯 出 的 檔 案 會 從 指 定 檔 名 的 副 檔 名 自 動 選 擇 對 應 的 檔 案 類 型 。

特 殊 檔 名 "-" 的 用 法 可 讓 Inkscape 將 影 像 資 料 寫 入 到 標 準 輸 出 (stdout)。

--export-overwrite

覆 寫 輸 入 檔 案 。

--export-type = 類 型 [,類 型 ]*

指 定 要 匯 出 的 檔 案 格 式 。 可 能 的 格 式 : svg, png, ps, eps, pdf, emf, wmf 與 每 種 現 有 匯 出 副 檔 名 的 檔 案 類 型 。 也 能 夠 一 次 匯 出 多 種 檔 案 類 型 。

注 意 PostScript 格 式 不 支 援 透 明 , 所 以 原 始 SVG 中 的 透 明 物 件 都 會 自 動 轉 換 成 點 陣 圖 。 用 到 的 字 型 會 為 子 集 合 並 嵌 入 。 預 設 匯 出 範 圍 是 頁 面 。 你 可 以 用 --export-area-drawing 將 匯 出 範 圍 設 定 為 繪 圖 。

備 註 PDF 格 式 會 保 留 原 始 SVG 的 透 明 度 。

--export-extension = 擴 充 模 組 識 別 碼

允 許 匯 出 時 使 用 的 特 定 輸 出 擴 充 模 組 , 尤 其 在 給 定 檔 案 類 型 有 多 個 匯 出 選 項 影 響 很 大 。 如 果 設 定 , 檔 案 副 檔 名 會 忽 略 --export-filename 和 --export-filename。 另 外 , 如 果 設 定 , 只 能 用 --export-type 給 定 一 種 檔 案 類 型 。

-C , --export-area-page

用 SVG、 PNG、 PDF、 PS 和 EPS 格 式 匯 出 範 圍 為 頁 面 。 這 是 匯 出 SVG、 PNG、 PDF 和 PS 的 預 設 值 , 所 以 你 不 必 指 定 此 選 項 除 非 你 使 用 --export-id 來 匯 出 指 定 的 物 件 。 目 前 EPS 尚 未 支 援 此 選 項 。

-D , --export-area-drawing

匯 出 SVG、 PNG、 PDF、 PS 和 EPS 時 , 匯 出 範 圍 為 繪 畫 部 份 (不 是 畫 布 ), 即 文 件 全 部 物 件 的 外 框 邊 界 (如 果 使 用 --export -id 則 是 匯 出 物 件 的 外 框 邊 界 )。 使 用 這 個 選 項 , 匯 出 的 圖 片 會 顯 示 文 件 中 所 有 的 可 見 物 件 , 而 不 會 有 頁 邊 空 白 或 裁 剪 。 這 是 EPS 預 設 的 匯 出 範 圍 。 對 於 PNG, 這 個 可 以 和 --export-use-hints 結 合 使 用 。

-a x0:y0:x1:y1 , --export-area = x0:y0:x1:y1

In PNG export, set the exported area of the document, specified in px (1/96 in). The default is to export the entire document page. The point (0,0) is the lower-left corner.

--export-area-snap

For PNG export, snap the export area outwards to the nearest integer px values. If you are using the default export resolution of 96 dpi and your graphics are pixel-snapped to minimize antialiasing, this switch allows you to preserve this alignment even if you are exporting some object’s bounding box (with --export-id or --export-area-drawing) which is itself not pixel-aligned.

-d DPI , --export-dpi = DPI

匯 出 PNG 所 使 用 的 解 析 度 。 當 匯 出 為 PS、 EPS 或 PDF (除 非 你 指 定 --export-ignore-filters 禁 止 點 陣 化 ) 時 , 也 用 於 退 回 套 用 濾 鏡 物 件 的 點 陣 化 過 程 。 預 設 值 為 96 dpi, 其 對 應 成 1 SVG 使 用 者 單 位 (px, 亦 稱 「 使 用 者 單 位 」 ) 匯 出 為 1 點 陣 圖 像 素 。 如 果 和 --export-use-hints 一 起 使 用 , 這 個 數 值 會 覆 蓋 DPI 內 定 值 。

-w 寬 度 , --export-width = 寬 度

匯 出 點 陣 圖 的 寬 度 , 單 位 為 像 素 。 這 個 數 值 會 覆 蓋 --export-dpi 設 定 值 (如 果 和 --export-use-hints 同 時 使 用 則 會 覆 蓋 DPI 內 定 值 )。

-h 高 度 , --export-height = 高 度

匯 出 點 陣 圖 的 高 度 , 單 位 為 像 素 。 這 個 數 值 會 覆 蓋 --export-dpi 設 定 值 (如 果 和 --export-use-hints 同 時 使 用 , 會 覆 蓋 DPI 內 定 值 )。

--export-margin = 間 距

匯 出 區 域 的 周 圍 加 入 間 距 。 用 頁 面 尺 寸 (SVG) 或 公 釐 (PS/PDF) 的 單 位 指 定 間 距 大 小 。 此 選 項 目 前 對 於 其 他 匯 出 格 式 沒 有 作 用 。

-i ID , --export-page = all|n[,a-b]*

Exports the selected pages only. If more than one page is specified then the resulting document may contain multiple pages if the format supports it.

Value can be a comma separated list of page numbers, or page ranges of two numbers separated by a dash. The keyword ’all’ can be used to indicate all pages would be exported.

-i ID , --export-id = 物 件 識 別 碼 [;物 件 識 別 碼 ]*

匯 出 PNG、 PS、 EPS、 PDF 和 普 通 SVG 時 , 你 想 要 從 文 件 中 匯 出 的 物 件 的 ID 屬 性 值 ; 其 他 剩 下 的 物 件 都 不 會 被 匯 出 。 預 設 情 形 下 匯 出 的 範 圍 是 物 件 的 外 框 邊 界 ; 你 可 用 --export-area (只 適 用 於 PNG) 或 --export-area-page 覆 蓋 這 項 數 值 。

如 果 你 用 物 件 的 分 號 分 隔 清 單 指 定 多 個 數 值 , 每 個 會 個 別 匯 出 。 這 裡 匯 出 的 檔 案 會 用 這 種 方 式 命 名 : [input_filename]_[ID].[export_type]

-j , --export-id-only

For PNG, PS, EPS, PDF and plain SVG export, only export the object whose id is given in --export-id. All other objects are hidden and won’t show in export even if they overlay the exported object. Without --export-id, this option is ignored.

-l , --export-plain-svg

用 普 通 SVG 格 式 匯 出 文 件 , 普 通 SVG 格 式 沒 有 sodipodi: 或 inkscape: 名 稱 集 和 RDF 後 設 資 料 。 使 用 --export-filename 選 項 指 定 檔 案 名 稱 。

--export-png-color-mode = COLORMODE

Sets the color mode (bit depth and color type) for exported bitmaps (Gray_1/Gray_2/Gray_4/Gray_8/Gray_16/RGB_8/RGB_16/GrayAlpha_8/GrayAlpha_16/RGBA_8/RGBA_16)

--export-png-use-dithering = false|true

Forces dithering or disables it (the Inkscape build must support dithering for this).

--export-ps-level = 等 級

設 定 PS 和 EPS 匯 出 的 語 言 版 本 。 目 前 支 援 PostScript 等 級 2 或 3。 預 設 版 本 為 3。

--export-pdf-version = 版 本

選 擇 要 匯 出 的 PDF 版 本 。 此 選 項 基 本 上 會 將 PDF 版 本 選 擇 器 顯 示 在 圖 形 介 面 的 PDF-export 對 話 窗 上 。 你 必 須 從 下 拉 式 選 單 中 選 擇 一 種 版 本 , 例 如 「 1.4」 。 預 設 的 pdf 匯 出 版 本 是 「 1.4」 。

-T , --export-text-to-path

在 適 用 情 形 下 (匯 出 PS、 EPS 和 PDF), 匯 出 時 將 文 字 物 件 轉 換 成 路 徑 。

--export-latex

用 以 建 立 LaTeX 文 件 的 圖 片 (適 用 PS、 EPS 和 PDF 匯 出 ) , 圖 片 的 文 字 則 由 LaTeX 排 版 。 當 匯 出 成 PDF/PS/EPS 格 式 時 , 此 選 項 會 將 輸 出 分 離 成 一 個 PDF/PS/EPS 檔 (例 如 用 --export-type 指 定 ) 和 LaTeX 檔 。 文 字 不 會 輸 出 到 PDF/PS/EPS 檔 案 , 但 是 會 出 現 在 LaTeX 檔 案 。 這 個 LaTeX 檔 案 會 包 含 PDF/PS/EPS。 輸 入 (\input{image.tex}) LaTeX 檔 案 到 你 的 LaTeX 文 件 會 顯 示 圖 片 和 全 部 由 LaTeX 排 版 的 文 字 。 查 閱 產 生 的 LaTeX 檔 案 可 得 知 更 多 資 訊 。 也 請 查 看 GNUPlot 的 「 epslatex」 輸 出 終 端 機 。

--export-ignore-filters

將 套 用 濾 鏡 的 物 件 (例 如 這 些 物 件 套 用 模 糊 ) 匯 出 成 向 量 屬 性 , 忽 略 濾 鏡 (匯 出 PS、 EPS 和 PDF 時 )。 在 預 設 情 況 下 , 全 部 套 用 濾 鏡 的 物 件 會 以 --export-dpi (預 設 為 96 dpi) 的 解 析 度 轉 成 點 陣 圖 以 維 持 外 觀 。

-t , --export-use-hints

匯 出 PNG 時 , 使 用 儲 存 在 匯 出 物 件 中 的 DPI 內 定 值 和 匯 出 檔 名 (只 能 和 --export-id 一 起 使 用 )。 當 你 從 Inkscape 內 部 匯 出 選 取 範 圍 時 會 自 動 設 定 為 這 些 內 定 值 。 例 如 , 你 用 Inkscape 圖 形 介 面 從 document.svg 裡 將 id="path231" 的 形 狀 以 300 dpi 匯 出 成 /home/me/shape.png , 並 儲 存 文 件 , 之 後 你 便 可 簡 單 地 用 下 面 的 指 令 以 相 同 的 解 析 度 重 新 匯 出 相 同 的 檔 案

inkscape -i path231 -t 文 件 .svg

如 果 你 將 這 個 選 項 和 --export-dpi、 --export-width 或 --export-height 一 起 使 用 , 那 麼 DPI 內 定 值 會 被 忽 略 並 使 用 命 令 列 上 的 數 值 。 如 果 你 將 這 個 選 項 和 --export-filename 一 起 使 用 , 那 麼 檔 名 內 定 值 會 被 忽 略 並 使 用 命 令 列 上 的 檔 名 。

-b 顏 色 , --export-background = 顏 色

匯 出 PNG 的 背 景 顏 色 。 這 可 以 是 任 何 SVG 支 援 的 顏 色 字 串 , 例 如 "#ff007f" 或 "rgb(255, 0, 128)"。 如 果 沒 有 設 定 顏 色 , 那 麼 就 會 使 用 在 Inkscape 文 件 選 項 對 話 窗 所 設 定 的 頁 面 顏 色 (儲 存 在 pagecolor= sodipodi:namedview 的 屬 性 )。

-y 數 值 , --export-background-opacity = 數 值

匯 出 PNG 背 景 的 不 透 明 度 。 這 個 數 值 可 以 是 0.0 到 1.0 之 間 的 數 值 (0.0 表 示 完 全 透 明 , 1.0 則 完 全 不 透 明 ) 或 是 大 於 1 到 255 以 內 的 數 值 (255 代 表 完 全 不 透 明 )。 若 沒 有 設 定 數 值 且 沒 有 使 用 -b 選 項 , 那 麼 就 會 使 用 在 Inkscape 文 件 選 項 對 話 窗 所 設 定 的 頁 面 不 透 明 度 (儲 存 在 inkscape:pageopacity= sodipodi:namedview 的 屬 性 )。 如 果 沒 有 設 定 數 值 但 有 使 用 -b 選 項 , 那 麼 會 使 用 255 (完 全 不 透 明 )。

-I , --query-id = 物 件 識 別 碼 [,物 件 識 別 碼 ]*

設 定 在 逗 號 分 隔 清 單 中 查 詢 尺 寸 的 物 件 識 別 碼 (ID)。 若 沒 設 定 , 查 詢 選 項 會 回 傳 繪 圖 尺 寸 (即 全 部 文 件 物 件 ), 而 非 頁 面 或 檢 視 框 。

如 果 你 用 逗 號 分 隔 清 單 指 定 多 個 數 值 , 使 用 --query-id 任 何 幾 何 查 詢 (例 如 (e.g. --query-x)) 會 回 傳 對 應 物 件 清 單 的 用 逗 號 分 隔 的 數 值 清 單 。

-S , --query-all

列 印 一 份 SVG 文 件 中 已 定 義 ID 的 所 有 物 件 以 逗 點 分 隔 的 清 單 , 與 x、 y、 寬 度 和 高 度 數 值 同 樣 。

-X , --query-x

查 詢 繪 圖 部 份 的 X 坐 標 或 用 --query-id 所 指 定 物 件 的 X 坐 標 。 回 傳 值 的 單 位 是 px (SVG 使 用 者 單 位 )。

-Y , --query-y

查 詢 繪 圖 部 份 的 Y 坐 標 或 用 --query-id 所 指 定 物 件 的 Y 坐 標 。 回 傳 值 的 單 位 是 px (SVG 使 用 者 單 位 )。

-W , --query-width

查 詢 繪 圖 部 份 的 寬 度 或 用 --query-id 所 指 定 物 件 的 寬 度 。 回 傳 值 的 單 位 是 px (SVG 使 用 者 單 位 )。

-H , --query-height

查 詢 繪 圖 部 份 的 高 度 或 用 --query-id 所 指 定 物 件 的 高 度 。 回 傳 值 的 單 位 是 px (SVG 使 用 者 單 位 )。

--vacuum-defs

從 SVG 檔 案 的 "<defs>" 段 落 中 移 除 所 有 未 使 用 的 項 目 。 如 果 這 個 選 項 與 --export-plain-svg 一 起 調 用 , 只 有 匯 出 的 檔 案 會 有 作 用 。 如 果 單 獨 使 用 會 適 當 地 修 飾 所 指 定 的 檔 案 。

--select = 物 件 識 別 碼 [,物 件 識 別 碼 ]*

而 --select 指 令 會 選 取 指 定 ID 的 物 件 。 你 可 用 逗 號 分 隔 的 清 單 選 擇 多 個 物 件 。 此 選 項 允 許 對 選 取 物 件 執 行 各 種 動 詞 。 使 用 "--verb=EditDeselect" 可 移 除 所 有 選 取 的 項 目 。 可 用 的 物 件 ID 取 決 於 文 件 指 定 載 入 哪 些 物 件 。

--actions = 動 作 (:參 數 )[;動 作 (:參 數 )]*

動 作 是 呼 叫 帶 有 單 一 參 數 函 數 的 新 方 式 。 使 用 --action-list 指 令 列 選 項 取 得 可 用 的 動 作 識 別 碼 (ID) 清 單 。 之 後 動 作 會 完 全 取 代 動 詞 (verb)。 目 前 任 何 動 詞 都 可 作 為 動 作 (無 參 數 ) 使 用 。 需 要 注 意 一 點 , 大 部 分 動 詞 需 要 GUI (即 使 動 詞 並 不 需 要 使 用 )。 使 用 --batch-process 會 處 理 結 束 後 會 自 動 關 閉 GUI。 另 外 全 部 的 匯 出 選 項 都 有 相 符 合 的 動 作 (移 除 選 項 前 面 的 ’--’ 並 用 ’:’ 取 代 ’=’)。

只 在 動 作 有 用 到 --batch-process 時 必 須 使 用 。

用 export-do 動 作 可 在 任 何 點 執 行 匯 出 。 這 允 許 單 個 檔 案 執 行 多 次 匯 出 。

--action-list

印 出 可 用 動 作 的 清 單 。

--actions-file = FILENAME

Execute all actions listed in the file. The file contents must be formatted using the syntax of --actions. This option overrides the --actions argument when both are given.

-g , --with-gui

試 著 使 用 圖 形 介 面 (在 Unix 系 統 , 即 使 沒 有 設 定 $DISPLAY 也 會 使 用 X server)。

-q , --active-window

Instead of launching a new Inkscape process, this will run the command in the most recently focused Inkscape document.

--display = DISPLAY

Sets the X display to use for the Inkscape window.

--app-id-tag = TAG

Creates a unique instance of Inkscape with the application ID ’org.inkscape.Inkscape.TAG’. This is useful to separate the Inkscape instances when running different Inkscape versions or using different preferences files concurrently.

--batch-process

執 行 全 部 動 作 或 動 詞 後 關 閉 GUI。

--shell

使 用 此 參 數 , Inkscape 會 進 入 互 動 式 命 令 列 殼 層 (shell) 模 式 。 於 此 模 式 中 , 你 在 提 示 符 位 置 上 輸 入 指 令 讓 Inkscape 執 行 , 而 不 需 針 對 每 一 道 指 令 執 行 新 的 Inkscape。 此 功 能 對 於 腳 本 和 伺 服 器 方 面 的 用 途 極 為 有 用 : 這 沒 有 加 入 任 何 新 功 能 , 但 可 讓 任 何 多 次 呼 叫 Inkscape 執 行 命 令 列 任 務 (比 如 匯 出 或 轉 換 ) 腳 本 的 速 度 更 快 、 消 耗 更 少 的 記 憶 體 。

在 殼 層 (shell) 模 式 Inkscape 會 預 期 輸 入 一 連 串 動 作 (或 動 詞 )。 這 些 操 作 會 逐 行 執 行 , 表 示 模 擬 按 Enter 鍵 的 典 型 行 為 。 可 以 將 全 部 動 作 彙 整 到 同 一 行 (但 不 一 定 是 必 須 這 樣 )。

This option can be combined with the --active-window parameter, to execute the shell commands in an already opened Inkscape document.

下 面 範 例 會 開 啟 檔 案 並 匯 出 為 兩 種 不 同 格 式 , 然 後 開 啟 其 他 檔 案 並 匯 出 單 一 物 件 :

file-open:file1.svg; export-type:pdf; export-do; export-type:png; export-do
file-open:file2.svg; export-id:rect2; export-id-only; export-filename:rect_only.svg; export-do

組 態 設 定

主 要 的 組 態 設 定 檔 放 在 ˜/.config/inkscape/preferences.xml; 組 態 設 定 檔 儲 存 各 種 設 定 值 , 可 在 Inkscape 中 變 更 (大 部 份 在 Inkscape 偏 好 設 定 對 話 窗 )。 也 可 以 在 那 裡 的 子 目 錄 中 放 置 你 自 己 的 組 態 設 定 檔 :

$HOME /.config/inkscape/extensions/ - extensions.

$HOME /.config/inkscape/fonts/ - fonts.

$HOME /.config/inkscape/icons/ - icon sets.

$HOME /.config/inkscape/keys/ - 鍵 盤 對 應 。

$HOME /.config/inkscape/paint/ - patterns and hatches.

$HOME /.config/inkscape/palettes/ - palettes.

$HOME /.config/inkscape/symbols/ - symbol files.

$HOME /.config/inkscape/templates/ - 新 增 檔 案 的 範 本 。

$HOME /.config/inkscape/ui/ - user interface files.

診 斷

程 式 執 行 成 功 時 會 回 傳 零 或 者 執 行 失 敗 時 回 傳 不 為 零 的 值 。

各 種 錯 誤 訊 息 和 警 告 可 列 印 到 STDERR 或 STDOUT。 如 果 程 式 怪 異 地 產 生 一 個 特 殊 的 SVG 檔 案 或 不 正 常 關 閉 , 它 是 查 看 這 次 輸 出 的 有 用 線 索 。

範 例

雖 然 Inkscape 很 明 顯 地 主 要 是 作 為 一 款 圖 形 介 面 的 應 用 程 式 , 但 同 樣 能 在 命 令 列 上 處 理 SVG。

用 圖 形 介 面 開 啟 一 個 SVG 檔 案 :

inkscape 檔 名 .svg

將 一 個 SVG 檔 以 預 設 的 解 析 度 96 dpi 匯 出 成 PNG (1 SVG 使 用 者 單 位 轉 變 成 1 點 陣 圖 像 素 ):

inkscape --export-filename=filename.png filename.svg

相 同 , 但 強 制 PNG 檔 案 為 600x400 像 素 :

inkscape --export-filename=filename.png -w 600 -h 400 filename.svg

相 同 , 但 匯 出 繪 圖 部 份 (全 部 物 件 的 外 框 邊 界 ), 不 是 頁 面 :

inkscape --export-filename=filename.png --export-area-drawing filename.svg

將 兩 個 不 同 檔 案 分 別 匯 出 四 種 不 同 的 檔 案 格 式 :

inkscape --export-type=png,ps,eps,pdf filename1.svg filename2.svg

將 id="text1555" 物 件 匯 出 成 PNG, 當 從 圖 形 介 面 匯 出 時 , 使 用 輸 出 檔 名 和 上 次 使 用 的 解 析 度 :

inkscape --export-id=text1555 --export-use-hints filename.svg

相 同 , 但 使 用 預 設 96 dpi 解 析 度 , 指 定 檔 名 , 並 且 向 外 捉 取 匯 出 範 圍 為 最 接 近 整 個 SVG 使 用 者 單 位 的 值 (維 持 物 件 的 像 素 校 正 , 因 此 最 小 平 滑 化 ):

inkscape --export-id=text1555 --export-filename=text.png --export-area-snap filename.svg

將 一 個 Inkscape SVG 文 件 轉 換 成 普 通 的 SVG:

inkscape --export-plain-svg --export-filename=filename2.svg filename1.svg

將 SVG 文 件 轉 成 EPS, 全 部 的 文 字 轉 換 成 路 徑 :

inkscape --export-filename=filename.eps --export-text-to-path filename.svg

查 詢 id="text1555" 物 件 的 寬 度 :

inkscape --query-width --query-id=text1555 filename.svg

再 製 id="path1555" 和 id="rect835" 的 物 件 , 將 再 製 物 件 旋 轉 90 度 後 , 儲 存 SVG 並 離 開 :

inkscape --select=path1555,rect835 --actions="duplicate;object-rotate-90-cw" --export-overwrite filename.svg

選 取 全 部 有 橢 圓 標 籤 的 物 件 , 將 物 件 旋 轉 30 度 後 , 儲 存 檔 案 並 離 開 程 式 。

inkscape --actions="select-by-element:ellipse;transform-rotate:30" --export-overwrite filename.svg

將 ID 為 MyTriangle 的 物 件 以 半 透 明 紫 色 背 景 匯 出 為 triangle_purple.png 檔 案 並 以 紅 色 背 景 匯 出 到 triangle_red.png 檔 案 。

inkscape --actions="export-id:MyTriangle; export-id-only; export-background:purple; export-background-opacity:0.5;export-filename:triangle_purple.png; export-do; export-background:red; export-background-opacity:1; export-filename:triangle_red.png; export-do" filename.svg

從 標 準 輸 入 (stdin) 讀 取 SVG 並 匯 出 成 PDF 格 式 :

cat filename.svg | inkscape --pipe --export-filename=filename.pdf

將 SVG 匯 出 成 PNG 格 式 並 寫 入 到 標 準 輸 出 (stdout), 然 後 用 ImageMagick 轉 換 程 式 轉 成 JPG 格 式 :

inkscape --export-type=png --export-filename=- filename.svg | convert - filename.jpg

與 上 面 的 相 同 , 但 差 別 在 於 從 管 線 讀 取 (這 裡 可 以 省 略 --export-filename)

cat filename.svg | inkscape --pipe --export-type=png | convert - filename.jpg

環 境 變 數

INKSCAPE_PROFILE_DIR

設 定 使 用 者 設 定 檔 目 錄 的 自 訂 位 置 。

INKSCAPE_DATADIR

設 定 Inkscape 資 料 目 錄 的 自 訂 位 置 (例 如 $PREFIX /share 是 否 Inkscape 的 共 用 檔 案 在 $PREFIX /share/inkscape)。

INKSCAPE_LOCALEDIR

設 定 翻 譯 分 類 的 自 訂 位 置 。

訪 問 此 網 址 取 得 更 多 資 訊 <http://wiki.inkscape.org/wiki/index.php/Environment_variables>

其 他 資 訊

搜 尋 Inkscape 資 訊 的 最 佳 地 點 是 在 <https://www.inkscape.org/>。 網 站 上 有 新 聞 、 說 明 文 件 、 教 學 、 範 例 、 郵 件 論 壇 存 檔 、 最 新 發 佈 的 程 式 版 本 、 程 式 錯 誤 和 功 能 需 求 資 料 庫 、 論 壇 ...等 等 。

參 見

potrace, cairo, rsvg, batik, ghostscript, pstoedit.

SVG 相 容 測 試 工 具 : <https://www.w3.org/Graphics/SVG/WG/wiki/Test_Suite_Overview>

SVG 驗 證 工 具 : <https://validator.w3.org/>

Scalable Vector Graphics (SVG) 1.1 規 範 W3C 建 議 (Recommendation) 2011 年 8 月 16 日 <https://www.w3.org/TR/SVG11/>

Scalable Vector Graphics (SVG) 1.2 規 範 W3C 工 作 起 草 (Working Draft) 2005 年 4 月 13 日 <https://www.w3.org/TR/SVG12/>

Scalable Vector Graphics (SVG) 2 規 範 W3C 候 補 建 議 (Candidate Recommendation) 2016 年 9 月 15 日 <https://www.w3.org/TR/SVG2/>

Document Object Model (DOM): 等 級 2 核 心 W3C 建 議 (Recommendation) 2000 年 11 月 13 日 <https://www.w3.org/TR/DOM-Level-2-Core/>

GUI 說 明

請 閱 讀 在 說 明 > 指 導 手 冊 和 說 明 > Inkscape 使 用 手 冊 的 資 料 來 學 習 Inkscape 圖 形 介 面 的 操 作 。

除 了 SVG 外 , Inkscape 可 以 匯 入 (檔 案 > 匯 入 ) 多 數 的 點 陣 圖 格 式 (PNG、 BMP、 JPG、 XPM、 GIF 等 )、 普 通 純 文 字 檔 (需 要 Perl)、 PS 和 EPS (需 要 Ghostscript)、 PDF 和 AI 格 式 (AI 版 本 9.0 或 更 新 )。

Inkscape 可 匯 出 32-位 元 PNG 圖 片 (檔 案 > 匯 出 PNG 圖 片 ), 也 可 從 檔 案 > 另 存 儲 存 成 AI、 PS、 EPS、 PDF、 DXF 及 一 些 其 他 格 式 。

Inkscape 能 用 繪 圖 板 畫 筆 的 壓 力 及 傾 斜 感 應 來 變 化 寬 度 、 角 度 和 一 些 工 具 的 作 用 力 , 包 括 美 工 筆 。

Inkscape 包 含 一 個 嵌 入 的 Potrace 點 陣 圖 描 繪 引 擎 (<http://potrace.sf.net>) 圖 形 介 面 前 端 。

Inkscape 能 使 用 外 部 腳 本 (stdin-to-stdout 過 濾 器 ), 腳 本 會 以 擴 充 功 能 選 單 上 的 命 令 方 式 呈 現 。 腳 本 可 以 有 設 定 各 種 參 數 的 圖 形 介 面 對 話 窗 , 而 且 能 透 過 命 令 列 取 得 所 選 物 件 的 ID。 Inkscape 提 供 各 式 各 樣 用 Python 寫 成 的 特 效 模 組 。

按 鍵 對 應

查 看 doc/keys.html 以 取 得 鍵 盤 和 滑 鼠 快 捷 鍵 的 完 整 清 單 , 或 在 說 明 選 單 中 使 用 按 鍵 和 滑 鼠 指 令 。

程 式 錯 誤

已 經 知 道 許 多 程 式 錯 誤 ; 請 到 網 站 (<https://www.inkscape.org/>) 檢 閱 已 回 報 的 錯 誤 並 回 報 新 發 現 的 問 題 。 也 請 看 看 你 使 用 版 本 的 發 佈 說 明 中 已 知 問 題 段 落 內 容 (檔 案 「 NEWS」 )。

歷 史

後 來 變 成 Inkscape 的 程 式 碼 庫 始 於 1999 年 的 程 式 Gill (由 Raph Levien 建 立 的 GNOME 繪 圖 程 式 )。 Gill 的 最 終 目 標 是 支 援 全 部 的 SVG。 Raph 實 現 了 PostScript 貝 茲 曲 線 成 像 模 型 , 包 括 邊 框 和 填 充 、 線 段 端 點 樣 式 、 線 段 接 合 樣 式 、 文 字 ...等 等 。 Raph 的 Gill 網 頁 位 於 <http://www.levien.com/svg/>。 Gill 的 開 發 工 作 在 2000 年 時 似 乎 已 經 變 慢 或 停 止 。

接 下 來 這 個 程 式 碼 庫 化 身 為 極 受 歡 迎 的 程 式 Sodipodi, 由 Lauris Kaplinski 主 導 。 經 過 數 年 的 發 展 , 這 個 程 式 碼 庫 已 轉 變 為 一 個 強 大 的 繪 圖 程 式 , 加 入 了 一 些 新 特 性 , 支 援 多 語 言 , 移 植 到 Windows 和 其 他 操 作 系 統 , 並 淘 汰 某 些 相 依 套 件 。

於 2003 年 時 由 四 名 活 躍 的 Sodipodi 開 發 人 員 - Bryce Harrington、 MenTaLguY、 Nathan Hurst 和 Ted Gould 成 立 Inkscape 計 劃 , 想 要 以 專 注 於 SVG 相 容 、 介 面 外 觀 風 格 和 開 放 開 發 機 會 吸 引 更 多 參 與 者 的 觀 點 為 程 式 碼 庫 帶 來 新 的 方 向 。 此 計 劃 進 展 迅 速 , 獲 得 許 多 非 常 活 躍 的 貢 獻 和 功 能 。

計 劃 早 期 的 許 多 工 作 專 注 於 程 式 碼 的 穩 定 和 國 際 化 。 從 Sodipodi 繼 承 的 原 始 圖 形 輸 出 引 擎 摻 入 許 多 數 學 角 , 因 而 導 致 當 程 式 超 出 正 常 使 用 範 圍 時 會 意 外 地 不 正 常 關 閉 ; 用 Livarot 取 代 原 本 的 圖 形 輸 出 引 擎 , 雖 然 不 夠 完 美 , 但 程 式 錯 誤 明 顯 地 減 少 。 此 計 劃 也 有 經 常 收 養 提 交 的 程 式 碼 的 做 法 , 並 鼓 勵 使 用 者 去 試 用 程 式 的 開 發 版 本 快 照 ; 這 有 助 於 迅 速 發 現 新 的 程 式 錯 誤 , 並 且 保 證 使 用 者 能 輕 易 地 校 驗 修 復 狀 況 。 因 此 , Inkscape 發 佈 的 版 本 已 經 普 遍 贏 得 了 穩 健 可 靠 的 聲 譽 。

同 樣 的 , 努 力 走 向 國 際 化 及 介 面 本 地 化 , 這 有 助 於 此 程 式 獲 得 世 界 各 地 的 幫 助 與 貢 獻 。

大 致 上 來 說 , Inkscape 已 經 在 開 放 原 碼 的 視 覺 魅 力 上 產 生 正 面 的 影 響 , 作 為 用 來 製 作 和 分 享 圖 示 、 啟 動 畫 面 、 網 站 設 計 等 的 工 具 。 從 某 一 點 來 看 , 「 這 只 是 一 個 繪 圖 程 式 」 , 但 Inkscape 已 經 扮 演 一 個 重 要 的 角 色 , 使 開 放 原 始 碼 帶 給 廣 大 愛 好 者 更 多 的 視 覺 饗 宴 。

作 者

這 個 程 式 碼 庫 的 存 在 要 歸 功 於 各 個 時 期 的 許 多 貢 獻 者 。 下 列 的 名 單 當 然 不 完 整 , 但 用 來 正 式 向 齊 心 致 力 於 這 個 程 式 的 許 多 人 致 謝 :

Maximilian Albert, Joshua A. Andler, Tavmjong Bah, Pierre Barbry-Blot, Jean-François Barraud, Campbell Barton, Bill Baxter, John Beard, John Bintz, Arpad Biro, Nicholas Bishop, Joshua L. Blocher, Hanno Böck, Tomasz Boczkowski, Adrian Boguszewski, Henrik Bohre, Boldewyn, Daniel Boles, Daniel Borgmann, Bastien Bouclet, Hans Breuer, Gustav Broberg, Christopher Brown, Marcus Brubaker, Luca Bruno, Brynn, Nicu Buculei, Bulia Byak, Pierre Caclin, Ian Caldwell, Gail Carmichael, Ed Catmur, Chema Celorio, Jabiertxo Arraiza Cenoz, Johan Ceuppens, Zbigniew Chyla, Alexander Clausen, John Cliff, Kees Cook, Ben Cromwell, Jon Cruz, Aurélie De-Cooman, Kris De Gussem, Milosz Derezynski, Daniel Díaz, Bruno Dilly, Larry Doolittle, Nicolas Dufour, Tim Dwyer, Maxim V. Dziumanenko, Moritz Eberl, Johan Engelen, Miklos Erdelyi, Ulf Erikson, Noé Falzon, Sebastian Faubel, Frank Felfe, Andrew Fitzsimon, Edward Flick, Marcin Floryan, Fred, Ben Fowler, Cedric Gemy, Steren Giannini, Olivier Gondouin, Ted Gould, Toine de Greef, Michael Grosberg, Bryce Harrington, Dale Harvey, Aurélio Adnauer Heckert, René de Hesselle, Carl Hetherington, Jos Hirth, Hannes Hochreiner, Thomas Holder, Joel Holdsworth, Christoffer Holmstedt, Alan Horkan, Karl Ove Hufthammer, Richard Hughes, Nathan Hurst, inductiveload, Thomas Ingham, Jean-Olivier Irisson, Bob Jamison, Ted Janeczko, Marc Jeanmougin, jEsuSdA, Lauris Kaplinski, Lynn Kerby, Niko Kiirala, James Kilfiger, Nikita Kitaev, Jason Kivlighn, Adrian Knoth, Krzysztof Kosiński, Petr Kovar, Michael Kowalski, Benoît Lavorata, Alex Leone, Julien Leray, Raph Levien, Diederik van Lierop, Nicklas Lindgren, Vitaly Lipatov, Ivan Louette, Fernando Lucchesi Bastos Jurema, Pierre-Antoine Marc, Aurel-Aimé Marmion, Colin Marquardt, Craig Marshall, Ivan Masár, Dmitry G. Mastrukov, David Mathog, Matiphas, Patrick McDermott, Michael Meeks, Federico Mena, MenTaLguY, Aubanel Monnier, Vincent Montagne, Tim Mooney, Derek P. Moore, Chris Morgan, Peter Moulder, Jörg Müller, Yukihiro Nakai, Victor Navez, Jonathan Neuhauser, Christian Neumair, Nick, Andreas Nilsson, Mitsuru Oka, Vinícius dos Santos Oliveira, Martin Owens, PBS, Alvin Penner, Matthew Petroff, Jon Phillips, Zdenko Podobny, Alexandre Prokoudine, Jean-René Reinhard, Alexey Remizov, Frederic Rodrigo, Hugo Rodrigues, Jean Franco Amoni Rodríguez, Juarez Rudsatz, Xavier Conde Rueda, Felipe Corrêa da Silva Sanches, Christian Schaller, Marco Scholten, Tom von Schwerdtner, Markus Schwienbacher, Danilo Šegan, Abhishek Sharma, Tim Sheridan, Shivaken, Rafał Siejakowski, Michael Sloan, John Smith, Sandra Snan, Boštjan Špetič, Aaron Spike, Kaushik Sridharan, Ralf Stephan, Dariusz Stojek, Patrick Storz, Martin Sucha, Sushant A.A., ˜suv, Pat Suwalski, Adib Taraben, Parcly Taxel, Hugh Tebby, Jonas Termeau, David Turner, Andre Twupack, Aleksandar Urošević, Alex Valavanis, Joakim Verona, Lucas Vieites, Daniel Wagenaar, Liam P. White, Sebastian Wüst, Michael Wybrow, Gellule Xg, Daniel Yacob, Masatake Yamato, David Yip, Wen-Wei Kao

著 作 權 和 許 可 證

Copyright (C) 1999-2023 by Authors.

Inkscape is free software; you can redistribute it and/or modify it under the terms of the GPL version 2 or later.