Binding specific tracks to hotkeys in foobar2000 possibly via autohotkey - autohotkey

I am looking for a way to attach hotkeys to specific tracks in foobar2000. I havent found a way to do it directly through foobar. Ive been trying to write down an autohotkey script which would skip songs until foobars window title matches destined tracks title, but ive been failing so far. If you have an idea on how to do this please help.

First disable this
Library=>Configure=>Shell Integration=>disable "Bring to front when adding new files
Then enable this
Playback=>Playback follows cursor
Then use this
^F1::Run,C:\MusicPlayer\foobar2000.exe /add /immediate "C:\path\to\song.mp3" /play

I am looking for a way to attach hotkeys to specific tracks in foobar2000. I havent found a way to do it directly through foobar
Actually, there is a way
We use the ability of foo_run to bind certain commands to a (global) shortcut.
Additionally we need foo_cmd_playlist to switch to the correct playlist because the used command context_command:play <path_to_mp3> works only if the corresponding playlist is active. Otherwise your track will be appended to the end of the active playlist or send to a new one according to your settings
How to set up
Download & install two foobar2000 plugins foo_run and foo_cmd_playlist
Under Preferences » Tools » Run services add a new entry for each track you need a shortcut. Enter a proper name as label
Under path: you enter
foobar2000 /playlist-activate:"Radio" /context_command:play http://listen.radionomy.com/themashupradio
/playlist-activate:"Radio" is where you define the playlist which has your desired track.
If you have a global playlist with all music in one, just take this playlist and you're fine
/context_command:play http://listen.radionomy.com/themashupradio is the place where you enter the full path to your mp3 (or online stream like my example)
At last, we set up a custom shortcut for our new entry under Preferences » Keyboard Shortcuts
All hail to the fb2k

Foobar2000 supports command line parameters. Simply passing the path of the mp3 file to foobar2000.exe works. Below uses the hotkey Ctrl + F1
^F1:: Run, %comspec% /c "C:\MusicPlayer\foobar2000.exe "C:\path\to\song.mp3"",, Hide

Related

Folder View Focus Disable Automatic Search

I would like to change the automatic find that happens when the Explorer Folder View is in focus:
Steps to reproduce (provided you have default bindings):
Open a workspace with files
Focus on the folders view
Start typing anything
This is to find files based on what you type (notice the find query in the top right) and the arrow keys skip to them. I would like to remap this feature to something like Ctrl+F (with a 'when expression', if possible) that way I can use other shortcuts for things like adding a new file. If this can not be remapped, I'm ok with disabling it, provided that's allowed.
I used to have the atom keymap extension that changed this but I removed it so I would be forced to learn all the default shortcuts so when I go into work I wouldn't be phased no matter what device I am on
I was looking through the atom keymap repo and found a comment on the main js file about 'new explorer filtration'. Interesting to see documentation being useful :p Anyways, I noticed they added a context setting so I changed the following user setting:
workbench.list.automaticKeyboardNavigation = false
Controls whether keyboard navigation in lists and trees is automatically triggered simply by typing. If set to false, keyboard navigation is only triggered when executing the list.toggleKeyboardNavigation command, for which you can assign a keyboard shortcut
We need either better setting id naming conventions or better ways to find settings, especially now that the list has grown substantially. I would have never guessed this would be the name of the setting, or list.toggleKeyboardNavigation being a trigger, since you aren't actually navigating

urxvt: Open graphical file explorer in the current folder

While the command line is very useful for most of the tasks, I sometimes resort to a graphical file explorer (like Nautilus, Thunar, PCmanFM). I would like a keyboard shortcut or a context-menu entry to open such a graphical file explorer _in the current directory. I know the converse is possible with nautilus-open-terminal. Is there currently a way to do that?
It may require writing a perl-extension, but I do not know enough of perl and urxvt to find how to capture the current PWD.
Assuming you're using Bash as your shell, here's an alias you could add to your .bashrc:
alias nh="nautilus file://$(pwd)"
I called it nh for "Nautilus here". So from the comman-line you would simply type:
nh
for a nautilus window in the shell's current directory.
I have no idea what's involved in adding something to the urxvt context menu - sorry.
Well, I quickly hacked a small extension to do this: https://github.com/raphaelfournier/urxvt-perl.
The opening of the file browser can be triggered with the right-click menu or a keyboard shortcut. The selection can be a directory, but also a filename, which will then be opened by the application associated with it in the file browser.

Edit Default rules from script in Beyond Compare

I have two files which I compare using Data Compare and I want to edit default rules from the script. I tried manually from BC interface and it worked, but I need to manipulate the rules within the script.
This is my script so far:
data-report layout:side-by-side &
options:ignore-unimportant,display-mismatches,line-numbers &
output-to:"%3" output-options:html-color "%1" "%2"
Any ideas how could I do that? I am using Beyond Compare 3.
Thanks in advance.
Beyond Compare doesn't support editing Data Compare session settings with a scripting command.
As a workaround, open a graphical Data Compare session. Click the Rules toolbar button (referee icon). In the Columns tab, edit the column settings you want to use in your script. Change the dropdown at the bottom of the dialog from Use for this view only to Also update session defaults before you click OK. The modified default session settings will affect your script.

Inject OnClick Event into running EXE

Is it possible with some program to to send an OnClick Event eg: MenuNewClick (File New) or others.
I have an application that has no Keyboard shortcuts.
When I use a Resource Editor I can see the Delphi Forms for each OnClick Event I need.
I would just like to be able to send these OnClick Events with Keyboard Shortcuts into the running exe.
Have used apps like Darker's Enabler, EDA Preview that allow you to modify the layout of a running exe.
Possible ?
Even this forum has options "Keyboard shortcuts
Enable keyboard shortcuts (when enabled, press ? for help)"
Thanks.
If the application is indeed made with Delphi and if it uses default TMainMenu component you could modify the RCData in which the .dfm is stored (this data alows you to view the form and its properties with programs like PE Exporer and similar) in a way that you change the AutoHotkeys property of TMainMenu to maAutomatic and then change ShortCut property of each menu item to contain proper keyboard shortcut.
If you have access to Delphi I recomend you first make an example application which will have all available shourctuts implemented so you could comparison the RCData between these two applications and made necessary changes.
NOTE: What I'm suggesting will require editing the EXE resource data so make sure you are working on a copy of the exe and not on the real one so you don't break your application.

How to run a macro in Netbeans

This is a silly question but spent the last 20 minutes or so browsing through google results and the menus of Netbeans. Under edit there is a start and stop macro recording but after saving the macro I can't seem to find how to run it.
Didn't assign a keyboard short cut to it assuming I can select to run a named macro from the menu somewhere but other than start/stop recording I can't find anything that'll list a macro so I can run it.
I have been googeling for a while too, and I could not find much. You can access to the key map and configure the shortcut for your macros. (Tools->Options->Key map). The macros can be accessed in the editor (Tools->Options->Editor)
There is another thread where I found it: Activating text editing macros on Netbeans
you need to record macro first
go to - edit
hit on - start macro recording
< write code which you want to add in macro >
after writing code - stop recording macros
then a popup box will appear, you have to set name and a shortcut key for that macro and that's it.
you can use that macro typing the shortcut key.
more info
Record another macro - this time assign it to a keystroke by clicking the Set Shortcut button in the dialog box. You will also see your previous macros when you do - and you can assign a shortcut to it as well.
You just need to change macro "Upload" for 'CTRL+s'
because in default its assigned to "Save as" (ctrl+s) and it doesn't upload the file while saving it.
Works for me!
go to the menu and click 'add shortcut' ;)
you create your own key shortcut which will start the macro.