How to switch to drafting table mode in LightTable? - lighttable

How can I switch to "Draft Table" mode in LightTable? Tried different sources (Ruby, Closure, Python). With Vim mode turned on and off. But I never see mode buttons in the right-bottom corner.

That video was just to demonstrate the concept, before the actual thing had been written. Those features aren't real (yet).

Related

Scripting to alter Bitbucket diff colours

I have quite a bad red/green colorblindess, and when I'm reviewing pull requests on BitBucket I really struggle to tell apart the red and green on it. Years ago I had a small script a friend wrote on the plugin Stylish to alter the colors (to a blue and a darker red) which was fantastic and really helped. I've lost it however and I'm not really experienced enough with this sort of coding to rewrite it.
Would anyone be able to give me some pointers for doing this?
Thanks
Windwos 10 provides Colorblind mode, it may be helpful if you are a Windows user.
Use Settings To Turn/Off Colorblind Mode
Navigate to the search box and type “color filter“.
You will see a list of search results, click Turn color filters on or off from the top.
Now you have to use the toggle button to “Turn on color filters” that is available under Use color filters.
You will see a list of color filters and color blindness filters, select the one that is suitable for you.
To quickly activate or deactivate the mode there is a keyboard shortcut to Turn On/Off Colorblind mode. You can always use Win+Ctrl+C keys to Turn On/Off your current filter.
Reference: Windows 10’s secret Colorblind mode

Standart window title buttons style - Close and Minimize

I need to make buttons that look like standard window title buttons with their icons (close/minimize) in the current operating system (win / osx / linux). Is there a possibility in qml?
You take screenshots (or google for images) of those buttons in their different states (enabled, pressed, highlighted, normal e.t.c), than you style your Buttons to show the right image at the right time.
Which set you need to choose, depends on the OS, which you can query with
Qt.platform.os
Depending on the usecase, it might be worth to investigate the possibility to use real Windows, if you are planning on building some kind of subwindows. Might prove complicated, though.

Ctrl+P and Ctrl+N for navigation in jupyter notebooks

I'm used to Emacs navigation, in particular Ctrl+P, N, F, and B, but I'm also used to Jupyter notebooks by now. The general question is: how to enable those shortcuts in a notebook?
What tickles me is the fact that on Mac those keybindings are already in place in a standard Anaconda IPython. But it's perfectly understandable since most system and browser shortcuts are bound to Cmd instead of Ctrl.
Since I spend a lot of time in Ubuntu, I wanted to reproduce the same behaviour here. It soon became apparent that most browsers hold some of the keybindings very dearly, such as Ctrl+P for print or Ctrl+N for New window. Turning these off is a huge matter in itself, so I decided to use another browser solely for the Jupyter Notebook, and Vivaldi seems like a nice choice since all shortcuts are easily customizable there.
I believed that with browser shortcuts being turned off, the IPython syntax would kick in, but none such thing has happened. Next I tried one of many manuals on the Jupyter notebook shortcuts customization (such as this one http://jupyter-notebook.readthedocs.io/en/latest/examples/Notebook/Custom%20Keyboard%20Shortcuts.html) to bind the 4 shortcuts I need. It works only up to some extent and only in the Jupyter inline magic:
%%javascript
Jupyter.keyboard_manager.command_shortcuts.add_shortcut('ctrl-p', 'jupyter-notebook:move-cursor-up')
What it does is that occasionally now the cursor in command mode does indeed move up when I press ctrl-p, but this behaviour is unstable. Moreover, after it moves, it immediately enters the edit mode in the cell above, which isn't happening if I simply press 'Up' arrow. As for the same trick for the edit mode:
%%javascript
Jupyter.keyboard_manager.edit_shortcuts.add_shortcut('ctrl-p', 'jupyter-notebook:move-cursor-up')
alas, it doesn't work at all.
Forgive me for the prolonged intro. The questions I have now are:
What is wrong with the key bindings I use in inline mode? Is it a silly mistake I made or a Jupyter glitch?
When I try to use these byndings through my custom.js file, they do not work. However, the file itself is recognized, e.g. the alert() commands work perfectly fine.
I've stumbled a few times on a emacs-bindings for the CodeMirror, however, as far as I understood, they are mostly used for copy-paste related matters rather than navigation, is it true? Would it help to use this set of bindings instead of pursuing the path with custom.js?
Thank you.
UPD
Installing emacs.js from CodeMirror and adding this code actually solved my problem. Just had to make sure that all conflicting browser keybindings were turned off.
require(["codemirror/keymap/emacs", "notebook/js/cell", "base/js/namespace"],
function(emacs_keymap, cell, IPython) {
cell.Cell.options_default.cm_config.keyMap = 'emacs';
var cells = IPython.notebook.get_cells();
for(var c=0; c< cells.length ; c++){
cells[c].code_mirror.setOption('keyMap', 'emacs');
}
}
);

Change behavior of mouse buttons - do I have to write a driver? (Sharkoon Drakonia)

I just bought a Sharkoon Drakonia (just for information). It has 11 buttons, but only two of them (except left, right and middle button of course) can be used as 4th and 5th mouse button (eg. in games), the other ones can only be modified to behave like a double click etc. via the configurator software shipped with the mouse. So I wondered if there is a way to completely change or remap (some of) the mouse buttons to be recognized in games as for example "Mouse 6" and "Mouse 7". I think I have to write a driver for it, am I right? Is there another way to achieve my aim?
Thank you in advance!
You don't necessarily have to write a new driver - you can use some input remapping software like GlovePie (google for it). It has its own scripting language to program how input works. Most people use it to make console controllers behave like a mouse, keyboard or combination of both... But I've used it to make things kinda like what you want.
There are other software like GlovePie that can also do the job, but it's the only one whose name I can remember right now.
edit: I've just read your question more carefully. You may not be able to make a software see a mouse6 or mouse7, but you can bind some action in a game to a key in the keyboard, and then map your extra mouse buttons to be seen as if they are those keys. It works just fine.

Quicktime X - How to hide mouse during screen capture?

I am attempting to record an app demo on the simulator, and want to use the Quicktime screen capture feature. However, I would like to hide the mouse during the capture.
Is this possible?
Doesn't seem to be a built in feature, so I am assuming I need to use some sort of plugin or hack.
Any suggestions?
QuickTime itself does not seem to offer this functionality therefore you have to resort to some other means to hide the cursor. On OSX there are some tools that allow this.
Cursourcerer is the first that springs to mind. However, as this really hides the cursor, it might not be ideal as you yourself will not be able to see what you are doing.
However, if you do not need to use QuickTime per se, it seems there are commercial screen recording solutions allowing this sort of thing such as Screenflow. I am not affiliated but the price seems reasonable and there is a demonstration of desired behavior here.
You don't record your app in your computer, but directly on your iPad or iPhone, connected to your Mac with a lightning cable. Then in Quicktime you select the "New movie recording" option (instead of "New screen recording"), then you will be able to select your iPad/iPhone as the "camera" and start recording your app running in your iOS device without any mouse pointer.
https://obsproject.com/
OBS can record your app window, and it ignores the cursor on the window.
Useful even if you are not a youtuber.
Cursorcerer for 10.14+ ⇨
http://doomlaser.com/cursorcerer-hide-your-cursor-at-will/
MouseHider.app for 10.13 and earlier ⇨ https://apps.apple.com/us/app/mouse-hider/id894419721?mt=12
I use option+command+k (⌥+⌘+k) to show / hide. It works globally.
It's also useful to hide the mouse cursor when you do the control-scroll zoom trick to focus in on a video.

Resources