What is the shortcut key to clear console in Eclipse or how can it be configured?
Any work-arounds to achieve this?
I know this thread is already 3 years old, but if someone is still looking for it, in Indigo the shortcut is Shift - F10 followed by r.
Cheers.
It does not appear to be a way, as there's a bug filled regarding this issue on bugs.eclipse.org.
I found a solution for the wiping the console in an Eclipse IDE. It uses the Robot class. Please see code below and caption for explanation:
import java.awt.AWTException;
import java.awt.Robot;
import java.awt.event.KeyEvent;
public void wipeConsole() throws AWTException{
Robot robbie = new Robot();
//shows the Console View
robbie.keyPress(KeyEvent.VK_ALT);
robbie.keyPress(KeyEvent.VK_SHIFT);
robbie.keyPress(KeyEvent.VK_Q);
robbie.keyRelease(KeyEvent.VK_ALT);
robbie.keyPress(KeyEvent.VK_SHIFT);
robbie.keyPress(KeyEvent.VK_Q);
robbie.keyPress(KeyEvent.VK_C);
robbie.keyRelease(KeyEvent.VK_C);
//clears the console
robbie.keyPress(KeyEvent.VK_SHIFT);
robbie.keyPress(KeyEvent.VK_F10);
robbie.keyRelease(KeyEvent.VK_SHIFT);
robbie.keyRelease(KeyEvent.VK_F10);
robbie.keyPress(KeyEvent.VK_R);
robbie.keyRelease(KeyEvent.VK_R);
}
Assuming you haven't changed the default hot key settings in Eclipse and import those java classes, this should work.
This thread is 7 years old now, but I constantly need to clean the console so i can get work done. Thanks to sbanders I made this AutoHotKey script:
#`::
WinGetTitle, Title, ahk_class SWT_Window0
if InStr(Title, "Eclipse") {
WinActivate, ahk_class SWT_Window0
Send +!q
Sleep, 1200
Send c
Send +{F10}r
}
return
What this means is the following.
When the user presses WinKey + Backtic (this can easily be changed to a different hotkey),
If an Eclipse window exists
Activate that window and press CTRL + SHIFT + q (opens navigation context menu)
Wait 1.2 seconds (wait time probably depends on system specs)
Press c (Will focus on console view)
Press SHIFT + F10 + r (Clears console)
End script
It's a very handy script for coders who don't like clicking so I thought I'd share it.
Press Shift + Alt + Q followed by C to set focus to console.
Then press Shift+F10 followed by R to clear it.
When I right-click inside the console window and select 'clear' it clears my console. I'm using Windows 10.
If you press Shift+F10+r that works.
Related
I make frequent use of SSMS's shortcut keys CTRL + K, C, to comment a block of code, and CTRL + K, U to uncomment.
Today, I went to do this, and noticed thatCTRL + K, U no longer works. Instead, it shifts focus to the availabile databases dialog in the top left of the screen, which apparently has the shortcut of CTRL + U.
I have checked the settings and CTRL + K, U is still mapped to uncomment selected code, but this is flat out not working.
Is this a bug, or something that I can fix?
SSMS v17.8.1
ApexSQL made patch to fix this problem
Choose Get updates for ApexSQL
Check show patches and press update
Seems to be an issue with ApexSQL refactor addin. I disabled it and the keyboard shortcut is working again.
Once every few hours this happens - when I press Shift-2 to get a ", and # appears. When I press Shift-' it puts in a " (although this only appears after pushing another key as well). I am on an English (as opposed to American) keyboard. I must be pressing some sort of shortcut key combination, but I don't know what it is. It goes away when I restart Eclipse. I can live with this problem, but I would rather not!
Anyone know what the shortcut I'm accidentally using is, so I can avoid it/correct it in future?
Edit: Windows 7
If you have several language layouts on the computer you are probably switching on them.
What OS are you using?
If Windows 7 the shortcut is ctrl + shift
http://www.tomshardware.com/forum/10444-63-shortcut-keys-keyboard-language-changing
If you're using windows XP i think the shortcut was alt + shift
If you are using Windows, pressing Ctrl + Shift changes keyboard layouts. In your case it seems to Switch to the US layout which has the # on Shift + 2
In my IDE, I have to first navigate to the option using mouse. Once I minimize or maximize the editor window once, Shift + Cmd + M starts working but not before that. Is there something I can do about it?
It seems strange. Would you check which command is binded to Shift+Cmd+M? Default shortcut for toggling maximize active view/editor is Ctrl+M. You can check this in Preferences > General > Keys or hit Cmd+Shift+L twice.
There are plenty of people asking and solutions for going from vs to eclipse, but unfortunately I'm going the other way. I'm an eclipse fan but I have to use vs 2010 now.
Does there exist a keybindings file I can import that will give me my favorite eclipse keyboard shortcuts?
Another alternative is to use AutoHotKey.
I am totally familiar with the pain of migrating from Eclipse to VS.
Anyway here is my AHK script. Just install AHK, edit/ this script as per your visual studio version and run it. You dont need to change anything in visual studio keybindings.
there are two ways of controlling any application on windows, either direct keyboard shortcuts with CTRL/SHIFT/ALT or using the ALT to activate menu bar and further typing F for FILE, E for EDIT and so on. The following script uses both types of shortcuts and it is up to you to decide which way you want to use the shortcuts.
I use following script for visual studio express 2012 version.
; ^ stands for Ctrl
; ! stands for Alt
; + stands for Shift
SetTitleMatchMode, 2
#IfWinActive, Microsoft Visual Studio Express ;any part of the name of the window
^PgDn::Send ^!{PgDn} ; next opened doc (tab navigation shortcut like in firefox/chrome)
^PgUp::Send ^!{PgUp} ; previous opened doc (tab navigation shortcut like in firefox/chrome)
^b::Send ^{F7} ; compile the current file
^/::Send ^{e}{c} ; comment Ctrl+e+c
^+/::Send ^{e}{u} ; uncomment Ctrl+e+u
^k::Send ^{F3} ; find next Ctrl+F3
^w::Send ^{F4} ; close tab Ctrl+f4
^Enter::Send {F12} ; go to defi/decl
^!Enter::Send ^+{g} ; open file under cursor (for headers) Ctrl+g
^+Enter::Send !{e}{i}{q} ; show quick info Alt+e+i+q (Using menu bar)
!Right::Send ^+{-} ; navigate last position
!Left::Send ^{-} ; navigate next position
^e::Send !{v}{i} ; error window
^+TAB::Send !{v}{p} ; solution explorer
; add here
return
#IfWinActive
You can only change them manually in the options I believe, but once you do you can export them for anytime you want to use them again (or release them for people who want the same keybindings). Unless of course someone wants to export their settings and give them to you.
Let's say I have a file with 10 lines and I have a problem with the name of the package (or something) and the cursor is on the last line of the text.
How can I go directly to that line to see what the problem is and what suggestions there are to remove the problem, using a shortcut?
Question: Is there a keyboard-shortcut for this?
Or something like this:
Go to the next error and Go to the previous error.
Windows and Linux
Go to the next error: Ctrl + .
Go to the previous error: Ctrl + ,
Show quick fixes: Ctrl + 1
Mac
Go to the next error: Cmd + .
Go to the previous error: Cmd + ,
Show quick fixes: Cmd + 1
To go to problem within project just type Shift+Alt+Q then press X. It will open the "Problems" window. Now use ↑ or ↓ to select the error/warning and press Enter to go to it.
I know it isn't simple as Crtl+. but it works for a whole project.
To complete the previous answers, you can use the combobox linked to the toolbar buttons for next/previous annotation to set the annotation level.
That makes browsing through errors using ctrl+./ ctrl+ easier,
TO GO TO NEXT ERROR ONLY in eclipse with Ctrl + . command, tick off warnings as shown in screenshot