lujun9972 / uimage

a iimage like minor mode, but with the ability to display url images
10 stars 3 forks source link

能否一个一个详细点的配置? #6

Open oaksharks opened 6 years ago

oaksharks commented 6 years ago

在 elpa中安装uimage之后然后 require , 在org文档中执行M-x uimage-mode 并没有看到图片? 是否需要别的配置?

lujun9972 commented 6 years ago

试试配置一下这个变量

(defcustom uimage-mode-image-regex-alist
  `((,(concat "\\(`\\|\\[\\[\\|<)\\)?"
          "\\(file:\\)?" "\\(\\(file://\\|ftp://\\|http://\\|https://\\)" uimage-mode-image-filename-regex "\\)"
          "\\(\\]\\]\\|>\\|'\\)?") . 3)
    (,(concat "\\(`\\|\\[\\[\\|<)\\)"
          "\\(" uimage-mode-image-filename-regex "\\)"
          "\\(\\]\\]\\|>\\|'\\)?") . 2))
  "Alist of filename REGEXP vs NUM.
Each element looks like (REGEXP . NUM).
NUM specifies which parenthesized expression in the regexp.
Examples of image filename patterns to match:
    file://foo.png
    `file://foo.png'
    \\[\\[file://foo.gif]]
    <file://foo.png>
    `foo.png'
    \\[\\[foo.gif]]
    <foo.png>
"
  :type '(alist :key-type regexp :value-type integer)
:group 'uimage)