org-mode 内的不同模式
Different modes within org-mode
如何定义标题级别的模式?我喜欢将数据存储在我的 org-mode 文件中,并在 headline-level 而不是 file-level 定义模式。所以我喜欢
* SQL Query (This should be in SQL-Mode)
Select * from sometable where some condition
* A Java Program ( This should be in Java-Mode)
public static void string..
您可以使用 source blocks。类似于:
* SQL Query (This should be in SQL-Mode)
#+BEGIN_SRC sql
Select * from sometable where some condition
#+END_SRC
* A Java Program ( This should be in Java-Mode)
#+BEGIN_SRC java
public static void string..
#+END_SRC
它不像您要求的那样无缝,但您可以使用 C-c '
打开源代码块并使用正确的主模式编辑缓冲区中的代码。
如何定义标题级别的模式?我喜欢将数据存储在我的 org-mode 文件中,并在 headline-level 而不是 file-level 定义模式。所以我喜欢
* SQL Query (This should be in SQL-Mode)
Select * from sometable where some condition
* A Java Program ( This should be in Java-Mode)
public static void string..
您可以使用 source blocks。类似于:
* SQL Query (This should be in SQL-Mode)
#+BEGIN_SRC sql
Select * from sometable where some condition
#+END_SRC
* A Java Program ( This should be in Java-Mode)
#+BEGIN_SRC java
public static void string..
#+END_SRC
它不像您要求的那样无缝,但您可以使用 C-c '
打开源代码块并使用正确的主模式编辑缓冲区中的代码。