如何在崇高的文本3中编辑被曝光的(光)主题

时间:2022-06-18 07:34:35

I am trying to edit some of the syntax colours in Sublime Text 3. I'm using the Solarized (Light) built in colour scheme but I only want to change a few of the colours. Where is the settings file (on a Mac)?

我正在编辑一些语法颜色在崇高的文本3。我使用的是在配色方案中内置的太阳能(光),但我只想改变其中的一些颜色。设置文件(在Mac上)在哪里?

6 个解决方案

#1


53  

I'd recommend using PackageResourceViewer to open the file. You could make your modifications there, and it would save in the proper location to override the built in files. However, I would recommend copying the contents of the file and creating a custom version in your User folder. That way, you can easily move it around and modify it without worrying about the built in color schemes.

我建议使用PackageResourceViewer来打开文件。您可以在那里进行修改,它将保存在适当的位置,以覆盖在文件中构建的文件。但是,我建议您复制文件的内容,并在您的用户文件夹中创建一个自定义版本。这样,您就可以轻松地移动它并修改它,而不必担心内置的配色方案。

The default color scheme files are located in Color Schemes - Default.sublime-package. In ST2, this was extracted to Packages/Color Scheme - Default. PackageResourceViewer will display these folders (as they would normally appear in the Packages folder in ST2. You could navigate to your color scheme from that.

默认颜色方案文件位于颜色方案- default .sublime-package。在ST2中,这被提取到包/配色方案-默认。PackageResourceViewer将显示这些文件夹(它们通常出现在ST2中的Packages文件夹中)。你可以从那里导航到你的配色方案。

#2


69  

I have managed to find a solution:

我设法找到了一个解决办法:

Go to http://tmtheme-editor.herokuapp.com (someone has built a web-based theme editor). Once you have tweaked the colour syntax you can download the themename.tmTheme file. Move that file to /Users/username/Library/Application Support/Sublime Text 3/Packages/ (if you are on a Mac).

访问http://tmtheme-editor.herokuapp.com(有人已经构建了基于web的主题编辑器)。一旦您调整了颜色语法,您可以下载themename。tmTheme文件。将文件移动到/Users/username/Library/Application Support/Sublime Text 3/Packages/(如果你在Mac上)。

Load in the syntax theme from the top menu: Sublime Text > Preferences > Color Scheme > themename.

从顶部菜单加载语法主题:崇高的文本>首选项>颜色方案>主题名。

If you want to tweak you syntax further up can upload the custom theme back in the web-based theme editor and save it out again.

如果想进一步调整语法,可以将自定义主题上载到基于web的主题编辑器中,然后再次保存。

Hope this helps someone else.

希望这能帮助别人。

#3


7  

Editing is way simpler than advices above.

编辑比上面的建议简单得多。

  1. Go to Sublime installation folder, find there Packages subfolder.
  2. 到崇高安装文件夹,找到那里包子文件夹。
  3. Open Color Scheme - Default.sublime-package as a zip archive (I use Total Commander and Ctrl+PgDn keys).
  4. 开放颜色方案-默认。sublime-package作为zip存档(我使用Total Commander和Ctrl+PgDn键)。
  5. Find there any scheme you like *.tmTheme, copy to HDD and edit with any XML editor.
  6. 找到任何你喜欢的方案*。tmTheme,复制到HDD并使用任何XML编辑器进行编辑。
  7. Pack modified file back (with Total Commander just copy file to opened archive).
  8. 打包修改后的文件(与总指挥官仅复制文件以打开存档)。

#4


7  

Sublime version, OS & OS version independent way:

崇高版,操作系统和操作系统版本独立方式:

In Sublime, at the top menu bar goto "Sublime Text 2/3" -> Preferences -> "Browse Packages...". This will open the "Packages" folder correctlin Finder/FileExplorer/Nautilus/... depending on OS/version-of-OS.

在崇高,在顶部菜单栏去“崇高的文本2/3”->偏好->“浏览包裹…”。这将打开“package”文件夹correctlin Finder/FileExplorer/Nautilus/…根据操作系统的操作系统。

如何在崇高的文本3中编辑被曝光的(光)主题

Find your theme and edit away.. 如何在崇高的文本3中编辑被曝光的(光)主题 Source

找到你的主题,然后编辑。源

#5


1  

This should be much easier than it is
I used parts of all the other answers to make this work.

这应该比我使用所有其他答案的部分使这个工作要容易得多。

Important notes before you begin:
1. I had used this menu item to select a colour scheme: Sublime Text > Preferences > Color Scheme
2. I chose "Monokai.tmTheme"
3. Therefore the file you need containing the colours is: Monokai.tmTheme
4. You will NOT have easy access to that file yet!!

开始前的重要注意事项:1。我使用这个菜单项来选择一个颜色方案:崇高的文本>偏好>颜色方案2。我选择了“Monokai。tmTheme”3。因此,您需要包含颜色的文件是:Monokai。tmTheme 4。您还不能轻松访问该文件!!

Overall Steps:
The overall steps I found to work are:
1. Get a copy of the Monokai.tmTheme text file
2. Place it in your "/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User" directory
(replace XXX with your username)
3. Again use this menu: Sublime Text > Preferences > Color Scheme
4. Choose the new entry "Monokai - User"
5. Any changes to your Monokai.tmTheme file will immediately be seen by Sublime Text

总体步骤:我发现工作的总体步骤是:1。拿一份Monokai的拷贝。tmTheme文本文件2。把它放在“/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User”目录(用您的用户名替换XXX) 3。再次使用此菜单:卓越的文本>首选>颜色方案4。选择新的条目“Monokai - User”5。你的Monokai有什么变化吗?tmTheme文件将立即被崇高的文本看到

Getting the Monokai.tmTheme text file :
This is the tricky part.
You have two options

Monokai。tmTheme文本文件:这是棘手的部分。你有两个选择

Option A. Use PackageResourceViewer to open the resource:
A1. Tools -> Command Palette
A2. Type "PackageResourceViewer"
A3. Choose "PackageResourceViewer: Open Resource"
A4. Navigate to "Color Scheme - Default"
A5. Navigate to "Monokai.tmTheme"
A6. This will open the contents of the file but it is NOT a real file on your disk! You must copy the contents into a new text document and save it into "/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User/Monokai.tmTheme" as above

选项A.使用PackageResourceViewer打开资源:A1。工具->命令调色板A2。输入“PackageResourceViewer”A3。选择“PackageResourceViewer: Open Resource”A4。导航到“颜色方案-默认”A5。导航到“Monokai。A6 tmTheme”。这将打开文件的内容,但它不是您磁盘上的真实文件!您必须将内容复制到新的文本文档中,并将其保存到“/Users/XXX/Library/Application Support/Sublime text 3/Packages/User/Monokai”中。tmTheme“如上所述

Option B. Use the web app to create your .tmTheme file:
B1. Goto http://tmtheme-editor.herokuapp.com
B2. Edit the colours
B3. Download the .tmTheme file
B4. Put it into "/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User/Monokai.tmTheme" as above

选项B.使用web应用程序创建. tmtheme文件:B1。转到http://tmtheme-editor.herokuapp.com B2。编辑颜色B3。下载. tmtheme文件B4。把它放到“/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User/Monokai”中。tmTheme“如上所述

#6


1  

As of May 2018 using Sublime Text 3:

从2018年5月开始使用崇高文本3:

I followed the Overall Steps and Option A. from @davidfrancis with great success to customize the Mariana color scheme.

我跟随@davidfrancis的整体步骤和选项a,成功定制了Mariana配色方案。

However, I had to change the file extension from <name>.tmTheme to <name>.sublime-color-scheme. Also, the filename can be anything you want (don't need to keep the default), and it will appear under Preferences > Color Scheme.

但是,我必须从 更改文件扩展名。 <名称> .sublime-color-scheme tmTheme。此外,文件名可以是任何您想要的(不需要保留默认),它将显示在首选项>配色方案下。

#1


53  

I'd recommend using PackageResourceViewer to open the file. You could make your modifications there, and it would save in the proper location to override the built in files. However, I would recommend copying the contents of the file and creating a custom version in your User folder. That way, you can easily move it around and modify it without worrying about the built in color schemes.

我建议使用PackageResourceViewer来打开文件。您可以在那里进行修改,它将保存在适当的位置,以覆盖在文件中构建的文件。但是,我建议您复制文件的内容,并在您的用户文件夹中创建一个自定义版本。这样,您就可以轻松地移动它并修改它,而不必担心内置的配色方案。

The default color scheme files are located in Color Schemes - Default.sublime-package. In ST2, this was extracted to Packages/Color Scheme - Default. PackageResourceViewer will display these folders (as they would normally appear in the Packages folder in ST2. You could navigate to your color scheme from that.

默认颜色方案文件位于颜色方案- default .sublime-package。在ST2中,这被提取到包/配色方案-默认。PackageResourceViewer将显示这些文件夹(它们通常出现在ST2中的Packages文件夹中)。你可以从那里导航到你的配色方案。

#2


69  

I have managed to find a solution:

我设法找到了一个解决办法:

Go to http://tmtheme-editor.herokuapp.com (someone has built a web-based theme editor). Once you have tweaked the colour syntax you can download the themename.tmTheme file. Move that file to /Users/username/Library/Application Support/Sublime Text 3/Packages/ (if you are on a Mac).

访问http://tmtheme-editor.herokuapp.com(有人已经构建了基于web的主题编辑器)。一旦您调整了颜色语法,您可以下载themename。tmTheme文件。将文件移动到/Users/username/Library/Application Support/Sublime Text 3/Packages/(如果你在Mac上)。

Load in the syntax theme from the top menu: Sublime Text > Preferences > Color Scheme > themename.

从顶部菜单加载语法主题:崇高的文本>首选项>颜色方案>主题名。

If you want to tweak you syntax further up can upload the custom theme back in the web-based theme editor and save it out again.

如果想进一步调整语法,可以将自定义主题上载到基于web的主题编辑器中,然后再次保存。

Hope this helps someone else.

希望这能帮助别人。

#3


7  

Editing is way simpler than advices above.

编辑比上面的建议简单得多。

  1. Go to Sublime installation folder, find there Packages subfolder.
  2. 到崇高安装文件夹,找到那里包子文件夹。
  3. Open Color Scheme - Default.sublime-package as a zip archive (I use Total Commander and Ctrl+PgDn keys).
  4. 开放颜色方案-默认。sublime-package作为zip存档(我使用Total Commander和Ctrl+PgDn键)。
  5. Find there any scheme you like *.tmTheme, copy to HDD and edit with any XML editor.
  6. 找到任何你喜欢的方案*。tmTheme,复制到HDD并使用任何XML编辑器进行编辑。
  7. Pack modified file back (with Total Commander just copy file to opened archive).
  8. 打包修改后的文件(与总指挥官仅复制文件以打开存档)。

#4


7  

Sublime version, OS & OS version independent way:

崇高版,操作系统和操作系统版本独立方式:

In Sublime, at the top menu bar goto "Sublime Text 2/3" -> Preferences -> "Browse Packages...". This will open the "Packages" folder correctlin Finder/FileExplorer/Nautilus/... depending on OS/version-of-OS.

在崇高,在顶部菜单栏去“崇高的文本2/3”->偏好->“浏览包裹…”。这将打开“package”文件夹correctlin Finder/FileExplorer/Nautilus/…根据操作系统的操作系统。

如何在崇高的文本3中编辑被曝光的(光)主题

Find your theme and edit away.. 如何在崇高的文本3中编辑被曝光的(光)主题 Source

找到你的主题,然后编辑。源

#5


1  

This should be much easier than it is
I used parts of all the other answers to make this work.

这应该比我使用所有其他答案的部分使这个工作要容易得多。

Important notes before you begin:
1. I had used this menu item to select a colour scheme: Sublime Text > Preferences > Color Scheme
2. I chose "Monokai.tmTheme"
3. Therefore the file you need containing the colours is: Monokai.tmTheme
4. You will NOT have easy access to that file yet!!

开始前的重要注意事项:1。我使用这个菜单项来选择一个颜色方案:崇高的文本>偏好>颜色方案2。我选择了“Monokai。tmTheme”3。因此,您需要包含颜色的文件是:Monokai。tmTheme 4。您还不能轻松访问该文件!!

Overall Steps:
The overall steps I found to work are:
1. Get a copy of the Monokai.tmTheme text file
2. Place it in your "/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User" directory
(replace XXX with your username)
3. Again use this menu: Sublime Text > Preferences > Color Scheme
4. Choose the new entry "Monokai - User"
5. Any changes to your Monokai.tmTheme file will immediately be seen by Sublime Text

总体步骤:我发现工作的总体步骤是:1。拿一份Monokai的拷贝。tmTheme文本文件2。把它放在“/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User”目录(用您的用户名替换XXX) 3。再次使用此菜单:卓越的文本>首选>颜色方案4。选择新的条目“Monokai - User”5。你的Monokai有什么变化吗?tmTheme文件将立即被崇高的文本看到

Getting the Monokai.tmTheme text file :
This is the tricky part.
You have two options

Monokai。tmTheme文本文件:这是棘手的部分。你有两个选择

Option A. Use PackageResourceViewer to open the resource:
A1. Tools -> Command Palette
A2. Type "PackageResourceViewer"
A3. Choose "PackageResourceViewer: Open Resource"
A4. Navigate to "Color Scheme - Default"
A5. Navigate to "Monokai.tmTheme"
A6. This will open the contents of the file but it is NOT a real file on your disk! You must copy the contents into a new text document and save it into "/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User/Monokai.tmTheme" as above

选项A.使用PackageResourceViewer打开资源:A1。工具->命令调色板A2。输入“PackageResourceViewer”A3。选择“PackageResourceViewer: Open Resource”A4。导航到“颜色方案-默认”A5。导航到“Monokai。A6 tmTheme”。这将打开文件的内容,但它不是您磁盘上的真实文件!您必须将内容复制到新的文本文档中,并将其保存到“/Users/XXX/Library/Application Support/Sublime text 3/Packages/User/Monokai”中。tmTheme“如上所述

Option B. Use the web app to create your .tmTheme file:
B1. Goto http://tmtheme-editor.herokuapp.com
B2. Edit the colours
B3. Download the .tmTheme file
B4. Put it into "/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User/Monokai.tmTheme" as above

选项B.使用web应用程序创建. tmtheme文件:B1。转到http://tmtheme-editor.herokuapp.com B2。编辑颜色B3。下载. tmtheme文件B4。把它放到“/Users/XXX/Library/Application Support/Sublime Text 3/Packages/User/Monokai”中。tmTheme“如上所述

#6


1  

As of May 2018 using Sublime Text 3:

从2018年5月开始使用崇高文本3:

I followed the Overall Steps and Option A. from @davidfrancis with great success to customize the Mariana color scheme.

我跟随@davidfrancis的整体步骤和选项a,成功定制了Mariana配色方案。

However, I had to change the file extension from <name>.tmTheme to <name>.sublime-color-scheme. Also, the filename can be anything you want (don't need to keep the default), and it will appear under Preferences > Color Scheme.

但是,我必须从 更改文件扩展名。 <名称> .sublime-color-scheme tmTheme。此外,文件名可以是任何您想要的(不需要保留默认),它将显示在首选项>配色方案下。