How to replace the c-q and c-s bindings for xon/xoff in Screen - gnu-screen

While using screen, I use in some application (ne, Nice Editor, to edit text files) the ctrl-q and ctrl-s bindings.
But these keys are bound to xon/xoff commands.
How could I replace these bindings, with (e.g. ctrl-& or ctrl-" or ctrl-o) modifying the .screenrc configuration file ?

One possible solution is to disable the flow control.
So to avoid C-q and C-s to be blocked by screen, one need to disable flow control.
This can be done using the flow off command while screen is running.
This can also be configured in the .screenrc file:
defflow off
This is sufficient and no other binding (or un-binding) are necessary.

Related

Disable vim mode in PhpStorm in debug

Is it possible to disable vim in certain windows/modes? For instance in debugger it's a bit annoying, also when editing cell values in Database mode it's not perfect.
Another question if a tab can switch to command mode when I'm about to navigate to another tab.
Thanks
It's currently not possible in IdeaVim 0.50. There is a feature request that partially covers what you're describing: VIM-765 Option to disable plugin in dialog boxes. Feel free to vote for this feature and/or file new requests at https://youtrack.jetbrains.com/issues/VIM.
You can remap <Tab> to gt using standard Vim mapping commands. Put them into your ~/.ideavimrc.

KDE Spectacle includeMousePointer on rectangular

The KDE Daemon global shortcuts allow to choose a shortcut for Take Rectangular Region Screenshot, it defaults to Meta+Shift+PrtScr.
However that takes a screenshot with the mouse pointer, how do I disable that?
When I open Spectacle, the includeMousePointer is not checked, so apparently that's a different setting.
Apparently this commit seems to say it's possible to do so but I don't know how.
If you press the hotkey, a D-Bus command is invoked. These commands accept arguments instead of looking at configuration files for maximum flexibility.
The actual D-Bus command that you would need to invoke is:
qdbus org.kde.Spectacle / org.kde.Spectacle.RectangularRegion false
The argument for this RectangularRegion method indicates the value for includeMousePointer. The commit you referenced indeed makes the default hotkey action call this with a true argument instead of false.
If you want to change the default, edit spectacle.khotkeys file in your system. Locate the [Data_1_4Actions0] section, and change Arguments=true to Arguments=false. The result should look like this:
[Data_1_4Actions0]
Arguments=false
Call=RectangularRegion
RemoteApp=org.kde.Spectacle
RemoteObj=/
Type=DBUS
It might be required to restart your session after changing this.

Add additional behaviour to existing Eclipse button?

I would like to add additional behaviour to an existing button in the Eclipse ide with a plugin.
To have an example, I would like to print to standard out each time the "Remove Launch" button in the console view gets pressed (see image).
Should I find and override/extend the corresponding, existing Handler with my logic?
Should I work with the these extensions?
ConsoleView extension locationURI="toolbar:org.eclipse.ui.console.ConsoleView"
Commands extension: "org.eclipse.ui.commands"
There isn't a general way to hook in to existing actions.
For Remove Launch you can set up a listener to be notified of removed launches by using the ILaunchManager:
ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager();
launchManager.addLaunchListener(listener);
The listener is an ILaunchesListener which has a launchesRemoved method that will be called when a launch is removed.

NSToolbar looks different in Leopard and Snow Leopard

I have a Cocoa app I'm working on and I get a different result in appearance for the NSToolbar I am using for the main window.
Specifically, I'm using a search field as the last NSToolbarItem and, whereas under Snow Leopard it is displayed correctly:
it is cut under Leopard:
Looking at those two versions it appears that the spaces I put between the items are not respected under Leopard. I also saw that sometimes, after I make some update at the toolbar in Interface Builder, these changes are not mirrored in the running application even under Snow. I have to drag the default bar from the customizing menu in order to see them.
UPDATE
The reason for the NSToolbar not always mirroring what is in the .nib file resides in the autosave mechanism that was enabled for me, as NSGod suggested.
What can be the cause of this misbehavior?
Is there something about constraints, (minimum and maximum) sizes that I should have taken into account?
Feel free to point some documentation to me
UPDATE 2
Is there a way to programmatically introduce item and spaces into a NSToolbar or check the consistency (at run time) of those entered with Interface Builder?
While I do recall having a couple of oddities with search fields in NSToolbars, I've never seen the behavior where the right side of it is cut off.
Are the NSToolbarItems that are spaces the fixed one-unit space, or the flexible spaces?
"I also saw that sometimes, after I
make some update at the toolbar in
Interface Builder, these changes are
not mirrored in the running
application even under Snow. I have to
drag the default bar from the
customizing menu in order to see them."
You need to keep in mind that if you've enabled user customization and autosave behavior in the toolbar, then when the user explicitly makes a change, it will be saved to user defaults. If you then re-arrange your toolbar in IB and run the app, it's possible that the configuration saved in user defaults is overriding the default configuration you've specified in the nib file.
What I usually do is during testing, delete the prefs file for my app so changes can't be overridden. (FWIW, I usually use an AppleScript saved as an application that I keep in my Dock. It just runs a do shell script command which deletes the prefs file. Being a GUI-oriented type of person, it's easier for me to just click it to have it run right before debugging. This version of the script asks for the prefs file to delete, though it can also be customized: http://www.markdouma.com/developer/DeleteAppPrefs.zip. If you've never run it before, you get the choose file dialog, and the chosen file is saved as an alias inside the actual AppleScript, so you're not asked again. You can drag the icon onto AppleScript Editor to take a look at the script or change it).
Anyway, then, if I'm going to release a new version of an app that uses a new toolbar layout, and want to prevent the config from being overridden, I'll change the toolbar's identifier (or autosave name) to something like "docToolbar2.0".

VB.NET call desktop application from 2 shortcuts - supply different parameters

I have a desktop application which reads files from a specified folder, then deposits the files to a folder in a third party document management system based on criteria that the user provides.
My question is:
is it possible to somehow provide different parameters to the code, depending on which shortcut of the application the user clicked on to start it up?
You can add command line parameters to a shortcut icon. Here's how you can do it in Windows:
On the Start Menu, navigate to Notepad.
Right click on Notepad and choose Send To > Desktop (Create Shortcut)
Right click on the newly-created desktop icon and choose Properties
Add your command line parameters to the Target text box.
For example, if you want notepad to open up the hosts file, this would be the content of Target property:
%SystemRoot%\system32\notepad.exe "C:\WINDOWS\system32\drivers\etc\hosts"
You can put pretty much anything into the Target property of a shortcut that you would put into a command line.
Yes.
The easiest way would be to have the shortcut pass those parameters in via the command line.
You could also use conditional compilation variables, and have 2 different .exes. You should be able to find samples of both approaches (command line and conditional compilation variable) in help.