UPDATE:
ไม่ได้สังเกตเห็นว่าองค์กรโหมด 9.2การเปลี่ยนแปลงกลไกของการขยายตัวแม่แบบที่org-structure-template-alist
เป็นเพียงบล็อกที่กำหนดโดยและ"#+BEGIN_"
"#+END_"
และไม่ชอบรายการที่ชอบ("p" ":PROPERTIES:?:END:")
อีกต่อไป
ตามที่กล่าวไว้ในลิงก์ด้านบนเทมเพลต "ซับซ้อน" อื่น ๆ สามารถกำหนดได้โดยฟังก์ชันtempo-define-template
และต้องโหลด org-tempo ( (require 'org-tempo)
) จริงๆแล้วรายการของorg-structure-template-alist
จะถูกแปลงเป็นorg-tempo-tags
ผ่านtempo-define-template
โดยorg-tempo
และorg-tempo-tags
ค่าเริ่มต้นเป็น:
(("<i" . tempo-template-org-index)
("<A" . tempo-template-org-ascii)
("<H" . tempo-template-org-html)
("<L" . tempo-template-org-latex)
("<v" . tempo-template-org-verse)
("<s" . tempo-template-org-src)
("<q" . tempo-template-org-quote)
("<l" . tempo-template-org-export-latex)
("<h" . tempo-template-org-export-html)
("<E" . tempo-template-org-export)
("<e" . tempo-template-org-example)
("<C" . tempo-template-org-comment)
("<c" . tempo-template-org-center)
("<a" . tempo-template-org-export-ascii)
("<I" . tempo-template-org-include))
สำหรับกรณีของคุณคุณสามารถกำหนดแม่แบบโดย:
(tempo-define-template "my-property"
'(":PROPERTIES:" p ":END:" >)
"<p"
"Insert a property tempate")
คำตอบด้านล่างใช้ได้เฉพาะกับรุ่นโหมดองค์กรก่อนหน้า 9.2
ใช่คุณสามารถเพิ่มรายการลงในแบบนี้:
(add-to-list 'org-structure-template-alist '("p" ":PROPERTIES:?:END:"))
จากนั้นในไฟล์ org คุณพิมพ์<p
และก็จะขยายไปยังสถานที่ให้บริการและออกจากจุดที่ตำแหน่งของTAB
?
C-h v org-structure-template-alist RET
และคุณสามารถหารายละเอียดเพิ่มเติมในเอกสารประกอบของตัวแปรโดยการพิมพ์
>
สัญลักษณ์ของtempo-define-template
การพิมพ์ผิดหรือเปล่า? ถ้าไม่ใช่ .... บทบาทของมันในนิยามคืออะไร?