gedit

Much needed: well-highlighted JSON log viewer

旧巷老猫 提交于 2019-12-03 04:16:42
问题 Using winston for node.js logging, I get json log files. A log file in this vein is simply a sequence of (newline delimited) json objects. This is great for log querying and treating logs as first-class data! However, both Sublime and gedit (at least the versions of them I'm using on Ubuntu, sublime 2 and gedit 3.6.2), poorly highlight json - they use the same color for keys and values, making any log drilling quite painful and really impossible to go through in any remotely humane manner.

Syntax Highlighting: How Does Eclipse Do It So Fast?

不问归期 提交于 2019-12-03 03:49:16
I've developed a syntax highlighter in Java for Android and it's working well, but the problem is it can be slow with big files. So I'm wondering how source code editors like Eclipse and Gedit (Ubuntu) highlight what you've just wrote so quickly. For example, if you enter the ending greater than symbol when writing a HTML tag, it highlights the tag instantly. How is it so quick, even with big files? Is there a specific way they go about doing it or do they just perform the syntax highlighting for the line you're on? Thanks, Alex I cannot talk for Gedit, but in Eclipse, we cheat :-) If you look

How to run a system command in Qt?

匿名 (未验证) 提交于 2019-12-03 02:45:02
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I have to run a system command in Qt. but I have to give an argument for that command. for example opening gedit with a text file. like "gedit /home/oDx/Documents/a.txt" but the path "/home/oDx/Documents/a.txt" will be in a variable like "docPath". so how can i do it!? 回答1: QProcess process; process.start("gedit", QStringList() << docPath); the same as above QProcess process; process.start("gedit", QStringList() << "/home/oDx/Documents/a.txt"); Also, read this . 回答2: QProcess::execute() may be helpful: QProcess::execute("gedit /home/oDx

How to configure gedit as git core.editor?

99封情书 提交于 2019-12-03 01:30:48
I have gedit configured as git core.editor. git config --global core.editor "gedit" This works fine unless there is already a gedit windows open. In that case, COMMIT_EDITMSG is opened in the existing window and gedit returns immediately. Git ends up with an empty commit message and fails. This site ( http://fabianschuiki.wordpress.com/2012/05/20/use-gedit-as-git-editor/ ) suggests using "gedit -s -w", but I don't have those options (and --new-window doesn't work): $ gedit -V gedit - Version 2.28.4 $ gedit --help Usage: gedit [OPTION...] [FILE...] - Edit text files Help Options: -h, --help

GEdit/Python execution plugin?

青春壹個敷衍的年華 提交于 2019-12-02 21:14:52
I'm just starting out learning python with GEdit plus various plugins as my IDE. Visual Studio/F# has a feature which permits the highlighting on a piece of text in the code window which then, on a keypress, gets executed in the F# console. Is there a similar facility/plugin which would enable this sort of behaviour for GEdit/Python? I do have various execution type plugins (Run In Python,Better Python Console) but they don't give me this particular behaviour - or at least I'm not sure how to configure them to give me this. I find it useful because in learning python, I have some test code I

Why do gedit and vim hide the final newline from the user?

痞子三分冷 提交于 2019-11-30 17:32:43
Let's assume we have two text documents: Our first file contains " hi " as text. Our second file contains " hi " as text. When we open these two files in gedit, vi, or vim, the two files are visually identical in every way. However, when we run xxd on the files, we get the following: Hex content of our first file reads: 6869 Hex content of our second file reads: 6869 0a Aha! There's an invisible newline. In vim, if we were paying close enough attention to the status bar and happen to understand what [noeol] means, then we might pick up on this, but in gedit, the two files open exactly the same

Option to display control characters in gedit

浪子不回头ぞ 提交于 2019-11-30 07:48:24
I'm a newbie to Linux. Is there a way to see the control characters in gedit. I went to options->preferences and all I got is option to see the line numbers of the text file. Is there any plugin that needs to be installed to see the same? I'm on Ubuntu 12.04 LTS and the gedit version is 3.4.1. There is a gedit-plugins package available for Ubuntu. Install that and take a look at the Draw Spaces section in the gedit preferences. You can configure it to show spaces, tabs, line feeds etc. You can use this command in a terminal: sudo apt-get install gedit-plugins 来源: https://stackoverflow.com

Why do gedit and vim hide the final newline from the user?

徘徊边缘 提交于 2019-11-30 01:18:16
问题 Let's assume we have two text documents: Our first file contains " hi " as text. Our second file contains " hi " as text. When we open these two files in gedit, vi, or vim, the two files are visually identical in every way. However, when we run xxd on the files, we get the following: Hex content of our first file reads: 6869 Hex content of our second file reads: 6869 0a Aha! There's an invisible newline. In vim, if we were paying close enough attention to the status bar and happen to

Block commenting in Gedit?

生来就可爱ヽ(ⅴ<●) 提交于 2019-11-29 20:16:21
Is there a way to comment out a chunk of highlighted code? I am programming in ruby, and I hate putting # on lines individually. 1.Install gedit plugins sudo apt-get install gedit-plugins 2.Go to Edit->Preference->Plugins-> and enable Code Comment 3.Ctl+m to comment block of codes 4.Ctl+Shift+m to uncomment block of codes Ruby has block commenting... =begin Insert comment here =end This will avoid the need to add # to each line... However, I don't think Gedit will convert highlighted code into commented lines by default. Just use a multi-line comment. Example: =begin Anything between a line

Math in reStructuredText with LaTeX

穿精又带淫゛_ 提交于 2019-11-29 19:51:44
I would like to use a lightweight markup language to take notes in my college classes. My editor of choice is gedit, and I found reStructuredText Tools for Gedit , which will run the reStructuredText processor and render the HTML in a pane in gedit. This is great, and 80% of the way there. But for many of my classes I need to include math equations or greek characters in my notes. Although I'm not very familiar with LaTeX, my understanding is that it has these capabilities. How can I use LaTeX in a reST document? Would the reST document need to be processed into LaTeX, then that rendered into