Copy LIne in qt shortcut - qt

I have been searching a lot on this but of no use. Is there any shortcut to copy an entire line with a keyboard shortcut in QT creator? I have seen shortcut for cutting a line but that's not what i want..

The shortcut list is user configurable in Tools menu -> Options -> Environment -> Keyboard.
And the default shortcut to copy a line is Ctrl + Ins.

Set cursor to the line you want copy and press Command+Alt+Down or Command+Alt+Up
That's it!
You can also move a line:
Mark the line you want to move and press Command+Shift+Down or Command+Shift+Up
Cheers!
ps: clearly they are shortcuts for mac!
pps: see also https://wiki.qt.io/Qt_Creator_Keyboard_Shortcuts

Related

Change gps behaviour on build target compile file

If I use the GNAT Programming Studio (GPS) to build a single file (Build target Compile file), the editor jumps to the first location in the file with a build warning/error.
It is possible to disable this behaviour using a setting?
Yes. That's apparently an "Advanced" feature, and a bit harder to find than other settings...
Open the Preferences dialog (Edit -> Preferences).
Next to the search preference... box, there's a menu icon. Click on it, and tick off the Show advanced preferences option. An Advanced category has now been added to the list on the left. In there, you will find a Jump to first location option.

Jupyter notebook markdown without mouse click

For markdown there is a shortcut like typing a number(1,2,3,4..) in command mode (Esc) and then giving an Enter
The thing is that your cursor gets before the "###" (if you used 3) where you also need to click the End key to be able to write.
Is there a way to overcome the last action as it is very annoying.
What you already have is a one click solution, which is going to be hard to beat. The only improvement I can think of is to override the functionality that's inserting the markdown headings for you. You could extend it to also place the cell in edit mode and move the cursor to the end. This would be placed in your custom.js file, which you place here: ~/.jupyter/custom/custom.js.

Set a shortcut in Atom editor for Go To Definition using go-plus

How can I set a shortcut in Atom editor for Go To Definition using go-plus. Thanks for your help in advance.
By default, the go-plus package uses Alt+Cmd+G to trigger the Go To Definition binding (as can be seen here). This binding will only work in files that use the Go grammar. Since Cmd is only available on Mac OS X, I don't know what keybinding other operating systems will use by default.
To redefine the keybinding, do the following:
Open the Atom Preferences, select the Keybindings section.
In the Search field, type 'go' to filter the list of keybindings.
Click the Copy icon next to the golang:godef keybinding.
Click the your keymap file link at the top.
This will open your keymap.cson file. Go to the end of the file and paste the copied content:
'atom-text-editor[data-grammar="source go"]:not(.mini)':
'alt-cmd-g': 'golang:godef'
Edit the keybinding to your liking and safe the file.
To verify the new keybinding, open the Key Binding Resolver view by selecting the Packages > Key Binding Resolver > Toggle menu entry. Open a Go file and press the keybinding you assigned, then watch the Key Binding Resolver view to see any conflicts.

How to quickly open a resource file by hovering on the file name in the code

Suppose a Qt qmake project has a source with a following line of code:
loadTxt(":/libraryNotes.txt");
If I want to open the "libraryNotes.txt" files in the target's resources, I need to go the "Projects" tab, open the "Resources", and look for the file, then click and open it.
Is there any shortcut to do it directly from the code editor pane, when the mouse cursor or text cursor is over the filename? I'm thinking of a way similar to pressing F2 to follow the symbol to its declaration/definition.
Unfortunately, this doesn't seem to be supported in Qt Creator 3.2.2 at least. But it shouldn't be too hard to add, most of the support code is already there.

How can I reset Xcode 4 keyboard shortcuts?

How can I reset Xcode 4 keyboard shortcuts to the default values? Thanks.
mv ~/Library/Developer/Xcode/UserData/KeyBindings/Default.idekeybindings ~/
This will make a backup copy just in case. Then start XCode, view the Keybinding preferences, and restart XCode. This will create a blank default Default.idekeybindings file.
Edit: As per the comment response, first Quit XCode. Then if you want to reset a particular binding, you'll have to edit the ~/Library/Developer/Xcode/UserData/KeyBindings/Default.idekeybindings File and remove the <key></key> element that has the keycode that was overridden, and the <string></string> element that comes after it.

Resources