Sublime Build 3126 : How to highlight all the line that contains my found phrase after searching? - search

I have an original version of Sublime Build 3126. Please, I need to learn the following if possible.
Basically, when I search for a term and click on the found line from the results window, I would like the Sublime editor to highlight the whole line that contains my term. At the moment, every time I click on the search result entries, I need to look again through the page for the line that contains the term. The Sublime editor is only highlighting the line number which is very hard to notice.
Ideally speaking, the whole line that contains the term might be highlighted and the term itself must be boxed/highlighted in a different way for instant identification.
If anyone knows how to adjust that to make it clear and easy to identify the found terms, it would be greatly appreciated.
I am using the Ubuntu version of Sublime.

Related

How to display a text file (.txt) as a code file with color in Sublime Text 3

I'm using sublime text 3. And I want to display a text with color like a code file in Sublime. But I don't know how to do. Please help me!.
Thanks you!
You can manually set the syntax of any file using the Command Palette and type "Set Syntax: " or from the bottom right dialog (by default it reads "Plain Text").
If you want Sublime Text to remember your choice, you can also do that from the syntax selection dialog mentioned above, or View > Syntax > Open all with current extension as…".
I think if you need your text file for purposes like note taking, there is a nice hack.
Go to View > Syntax and then select haskell. Haskell syntax highlighting is subtle and works fine. To highlight something just capitalise the first letter and it pops in a different colour. Numbers are highlighted in a different colour again, increasing readability. Finally brackets commas etc have different colour which further helps.
Well, coloring is based on the syntax, like every programming language has its syntax, but the pure text file is hard to detect the syntax since it can be anything. So if you use the Sublime to coding,try save it as a file with file extension first, then the Sublime will detect by itself, however you could also do this manually.
The ability to create your own syntax highlighting rules is one of the excellent features of SublimeText.
Have a look here at some other people wanting to build their own syntax highlighting rules:
How to not highlight object keys such as 'do'/'package' as keywords in Sublime?
Sublime Text - C++ Highlight
That explains the basic tools you need to use to do what you want to do.
Following the same ideas there you can build a syntax highlighting scheme for whatever it is you want to achieve in your text file based on whatever syntax rules you are trying to follow. Hard to imagine what those are for a text file without you supplying exact details but if you want to do it Sublime Text gives you the power to do it.
If you give that a try and have trouble with developing the relevant Regular Expression/s to do what you want to do then post what you have done and how it is not working the way you hoped and perhaps we can help you get to the end of the game.

2 spaces indentation in google Docs

To prepare an exam, I have to learn coding using google docs rather than using an IDE. It may seem idiot or impratical but the teacher really insists on that. It seems that is the same thing as Google interviews for example...
So far, I really got used with using two spaces indentation (I hate using tab indendation). And I want to learn how can I do that quickly in Google docs. Is there a shortcut or a "tips" (add-on?) for that?
For example, if you have an "if-condition" starting at the position number 4 and you want to move to the following line, it can be really convenient to have the cursor position at 4. Then, you'll add two spaces to start your block at position number 6. (ALL the if block will have at least position 6). But in Docs, when you move to the following line, the cursor always start at the beginning of the line except if you use the tab indentation. And it's really shitting if you want to indent your code properly...
Do you have a solution for that please ?
I was facing the same problem.
To write Python code in google docs, my solution is:
Switch off auto-capitalization, auto-correction and smart quotes. And other auto-substitutions so that you may write code without docs like formatting.
To do this: Tools> Preferences and uncheck the above items. Screen shots attached below.
Set tab to two spaces.
Right-click on ruler on top of page. Add left-tab stop, an arrow will appear, move this tab stop to 2 spaces from left of ruler. Try adding tab in the current line and if the tab size is OK, save this formatting.
To save:
Format > Paragraph Styles > Normal Text > Update 'Normal Text' to match.
Last, to add color(synatx highlight), you may use 'code blocks extension'.
Click install.
Now, write code in docs, select the code in google doc, click on:
Add-ons > Code Block. A pop up opens up.
Choose language : 'python' for me.
Choose theme: 'atom-one-dark'
click Format.
The code looks much like IDE, and writing more code is easier too.
While I understand that sometimes a point can be made by making students do things in a way that might not seem logical, this one doesn't make any sense to me.
Students don't learn anything useful by pressing space twice instead of letting an editor or IDE do it for them.
I wonder, is it because he/she wants it delivered in Google Docs or because they want you coding that way? If it's the latter, you won't have to hide your workaround.
I can only suggest using a good text editor, I always use the excellent and free Notepad++, and copy and paste it to and from Google Docs. Your instructor will never know. In fact, I'd be hunting around to see of there was a way to access your code files directly in Google Docs from Notepad++, or to auto-sync a folder with Google docs.
Notepad++ has syntax colouring - which will save your life - and can be set to indent with tabs or spaces to whatever indent width you specify. If not using an IDE, I only use Notepad++.
Your instructor sounds like some I had, people who cross a line from being quirky but with a point to make to just being a dick. There is absolutely no point in telling a student to code only in Google docs. Google docs is a great thing, I love it, but it is by no stretch of the imagination a coding tool.
(I see that this is an aged thread, but I'll respond in case someone else with a similar issue - like this year's class for that course - comes looking for an answer.)
You could try (ab)using bulleted lists:
Insert a bulleted list
Right click on the bullet, select "More bullets..."
In the "Symbol" selection list, choose "Format & whitespace" and select one of the whitespace options as bullet char
Repeat for as many levels (of bullet sub-lists) as you think you may need in your program
Fix indentation to match whatever feels best for you
Every time you need to write a nested block, you will have to press "tab" only once, then bullet list level is kept and the indentation with it. To go back to the outer block, just press shift-tab.
However, IMHO it doesn't worth the trouble. Generally, interview question solutions are not that large and hitting spacebar a couple of times is not much of an overhead.
It's somewhat cumbersome but you can set as many tab stops as you want, and docs will move nested tabs to the next tab stop as well. For example:
You can add tab stops by right clicking on that tab bar where you want the tab stop to be and clicking Add left tab stop. You'll want to have all text in the document selected if you want the tab stop to apply everywhere.

Vim editor showing additional two columns

When I open a file in vim editor, after a few seconds, a additional two columns with random text appears in the window. Can anyone tell me, what it is and how to rectify it?
I am attaching a screen-shot of the problem :
Sigh…
That column is the "sign column" and you can read about it and the related "signs" feature in :help signs.
What you see is the marks present in your file as displayed by a plugin, most likely ShowMarks.
If you don't want it, why did you install it?

GUI text editor with syntax highlighting + background text highlighting

Looking for a GUI based text editor that has syntax highlighting for some of the more commonly used languages, plus manual text backround highlighting. Like you can permanently highlight selections of text, not just 'current line highlighting' or changing the default background color for 'currently selected' text. I thought notepad++ had this, but I haven't been able to tell how to access it if so.
I've only been able to find editors that do one or the other so far. Mostly just want this for studying purposes.
Have a look at AvalonEdit from the SharpDevelop project. Might be what you're looking for. Or at least a good basis to develop your own.

Dreamweaver source code view, is it possible to add "tags"?

I do'nt know if this is possible or if its called tags
im using dreamweaver cs4, in source mode view it displays line numbers to the left, I wish I could add some kind of "tag" to a certain line, and then have some sort of menu where it scrolls me to the tag.
Does this makes any sense?
It's because I have a huge source file that I need to navigate a lot in different places while coding and this "feature" would make my life a LOT easier.
Any help is appreciated.
Best Regards
It sounds like you're looking is what I've heard called a number of times "bookmarking". Unfortunately, Dreamweaver does not have this functionality built in. Not quite the same thing, but if you remember the line number you can jump to the line using a keyboard shortcut: CTRL+G on Windows, I think Cmd+, on Mac this pop up a little dialog you can enter the line number and hit enter to jump to that line.

Resources