Installing and using NeXT OPENSTEP in VirtualBox for Linux

Fitzcarraldo
, 12/11/2019 | Source: Fitzcarraldo's Blog

Introduction and some history My first micro computer was an Apple II+, which I used extensively both for work and leisure. In fact I liked it so much that I bought a //e when Apple Computer, Inc. released that model. I was not tempted by the Apple /// or Lisa when they were released, although […]

Replacing the KDE Plasma widget ‘Thermal Monitor’ with ‘Kargos’ in Gentoo Linux

Fitzcarraldo
, 01/11/2019 | Source: Fitzcarraldo's Blog

The KDE Plasma widget Thermal Monitor has not been working correctly in my Gentoo Linux installations for quite some time. I notice Thermal Monitor’s repository has not been updated for a couple of years, despite several new versions of KDE Plasma having been released. Perhaps that is the reason. On my laptop running the Stable […]

How to enable a Windows application in WINE to access a Samba share on a NAS (continued)

Fitzcarraldo
, 26/10/2019 | Source: Fitzcarraldo's Blog

In a 2016 post ‘How to enable a Windows application in WINE to access a Samba share on a NAS‘ I explained how to mount in Linux a networked SMB shared folder so that a Windows application running via WINE could access the folder as Drive Y: in order to open and save files in […]

Make the Macbook touchpad works like MacOS (a modern and definitive guide)

Menelkir
, 26/10/2019 | Source: Daniel Menelkir

There's a lot of tutorials about that on the internet, I'll try to be as much distribution-agnostic as possible. If your distribution doesn't the package that I'm talking about, you should search elsewhere or compile yourself.

Requirements:

A working Xorg (not sure if works with wayland) and a working DE/WM
xbindkeys
xdotool
dispad
mtrack driver

Recipe:

Uninstall whatever the touchpad driver you're using, like synaptics, and install mtrack. And use the following configuration for that (in /etc/X11/xorg.conf or /etc/X11/xorg.conf.d/10-mtrack.conf):

Section "InputClass"
        MatchIsTouchpad "on"
        Identifier      "Touchpads"
        MatchDevicePath "/dev/input/event*"
        Driver          "mtrack"
        # The faster you move, the more distance pointer will travel, using "polynomial" profile
        Option          "AccelerationProfile" "2"
        # Tweak cursor movement speed with this
        Option          "Sensitivity" "0.08"
        # Pressure at which a finger is detected as a touch
        Option          "FingerHigh" "5"
        # Pressure at which a finger is detected as a release
        Option          "FingerLow" "5"
        # I often use thumb to press down the physical button, so let's not ignore it
        Option          "IgnoreThumb" "true"
        Option          "ThumbRatio" "70"
        Option          "ThumbSize" "25"
        # Ignore palm, with palm takes up to 30% of your touch pad
        Option          "IgnorePalm" "true"
        Option          "PalmSize" "30"
        # Trigger mouse button when tap: 1 finger - left click, 2 finger - right click, 3 - middle click
        Option          "TapButton1" "1"
        Option          "TapButton2" "3"
        Option          "TapButton3" "2"
        Option          "TapButton4" "0"
        Option          "ClickTime" "25"
        # Disable tap-to-drag, we're using three finger drag instead
        Option          "TapDragEnable" "false"
        # While touching the touch pad with # fingers, press the touchpad physical click button
        Option          "ClickFinger1" "1"
        Option          "ClickFinger2" "3"
        Option          "ClickFinger3" "2"
        Option          "ButtonMoveEmulate" "false"
        Option          "ButtonIntegrated" "true"
        # The momentum after scroll fingers released
        Option          "ScrollCoastDuration" "300"
        Option          "ScrollCoastEnableSpeed" ".1"
        # Natural scrolling with two fingers
        Option          "ScrollSmooth" "true"
        Option          "ScrollUpButton" "5"
        Option          "ScrollDownButton" "4"
        Option          "ScrollLeftButton" "6"
        Option          "ScrollRightButton" "7"
        # Tweak scroll sensitivity with ScrollDistance, don't touch ScrollSensitivity
        Option          "ScrollDistance" "250"
        Option          "ScrollClickTime" "10"
        # Three finger drag
        Option          "SwipeDistance" "1"
        Option          "SwipeLeftButton" "1"
        Option          "SwipeRightButton" "1"
        Option          "SwipeUpButton" "1"
        Option          "SwipeDownButton" "1"
        Option          "SwipeClickTime" "0"
        Option          "SwipeSensitivity" "1500"
        # Four finger swipe, 8 & 9 are for browsers navigating back and forth respectively
        Option          "Swipe4LeftButton" "9"
        Option          "Swipe4RightButton" "8"
        # Mouse button >= 10 are not used by Xorg, so we'll map them with xbindkeys and xdotool later
        Option          "Swipe4UpButton" "11"
        Option          "Swipe4DownButton" "10"
        # Mouse buttons triggered by 2-finger pinching gesture
        Option          "ScaleDistance" "300"
        Option          "ScaleUpButton" "12"
        Option          "ScaleDownButton" "13"
        # Mouse buttons trigger by 2-finger rotating gesture, disabled to enhance the pinch gesture
        Option          "RotateLeftButton" "0"
        Option          "RotateRightButton" "0"
EndSection






By now, your trackpad will be working with a lot better. Pay attention to the comments if you need to customize. Now we'll create a map for what we still need. You can adjust the modifiers to fit your needs, or just remap then in your DE/WM. Create a $HOME/.xbindkeysrc with this:

# Next Workspace (Swipe4Left)
"xdotool key --clearmodifiers Control_L+Alt_L+Left"
   b:8
# Previous Workspace (Swipe4Right)
"xdotool key --clearmodifiers Control_L+Alt_L+Right"
   b:9
# Desktop Grid (Swipe4Down)(F4 key)
"xdotool key --clearmodifiers XF86LaunchA"
   b:11
# Toggle Present Windows (Current Desktop) (Swipe4Up)(F5 key)
"xdotool key --clearmodifiers XF86LaunchB"
   b:10
# Zoom in
"xdotool key ctrl+21"
   b:12
# Zoom out
"xdotool key ctrl+20"
   b:13


Dispad have a better touchpad-ignore than mtrack, so we're using it. Create this configuration at $HOME/.dispad (I know, it could be .dispadrc but the default is .dispad so I'll keep it):

# name of the property used to enable/disable the trackpad
property = "Trackpad Disable Input"
# the value used to enable the trackpad
enable = 0
# the value used to disable the trackpad
disable = 1
# whether or not modifier keys disable the trackpad
modifiers = false
# how long (in ms) to sleep between keyboard polls
poll = 48
# how long (in ms) to disable the trackpad after a keystroke
delay = 500


With the files in place, now we need to create a $HOME/.xprofile:

xbindkeys -f $HOME/.xbindkeysrc
dispad -c $HOME/.dispad

Reboot



Sources used:

https://int3ractive.com/2018/09/make-the-best-of-MacBook-touchpad-on-Ubuntu.html
https://bill.harding.blog/2017/12/27/toward-a-linux-touchpad-as-smooth-as-macbook-pro/



Creating a RAID of USB pendrives in Linux

Fitzcarraldo
, 17/10/2019 | Source: Fitzcarraldo's Blog

If you’re not familiar with the RAID (Redundant Array of Inexpensive Disks) concept and the different types of array, the article ‘RAID 0, RAID 1, RAID 5, RAID 10 Explained with Diagrams‘ gives a quick summary (and links to another article ‘RAID 2, RAID 3, RAID 4, RAID 6 Explained with Diagram‘). Another helpful article […]

Firewall zones (profiles) in Linux, and how to switch them automatically if you use UFW

Fitzcarraldo
, 04/10/2019 | Source: Fitzcarraldo's Blog

Firstly, a note on terminology: UFW (Uncomplicated Firewall) and its two GUI front-ends Gufw and UFW Frontends use the term ‘application profile’ to refer to a pre-configured set of rules specified in a file. Files containing UFW application profiles are placed in the directory /etc/ufw/applications.d/. An application profile for SMB, for example, enables the root […]

Paul Gideon Dann’s patchset for Poppler to enable Okular (Qt5) to use Cairo rather than Splash to render PDF files

Fitzcarraldo
, 27/09/2019 | Source: Fitzcarraldo's Blog

If you view the same PDF file in Okular (KDE) and Evince (GNOME), you may notice that fonts and lines are rendered better in Evince. Both applications use Poppler to render text and graphics in PDF files, but Poppler uses a different rendering backend in the two applications. For Evince Poppler uses the Cairo library, […]

The fragmentation

Menelkir
, 26/09/2019 | Source: Daniel Menelkir

Since  a lot of stupid people loves to say that all the time, let me explain using your falacies arguments.

Too many package managers

No, there's not "too many package managers", this is called choice. You can CHOOSE what use it. Like portage? Use gentoo. Like apt? Use a debian-oriented. And the list goes on. Don't like rpm? Then use something that doesn't use it and be happy. No one is obligated to use something just because you like it. Having choices is good for everyone, maybe not for you. 

Too many desktop managers/window managers

Again, you can choose one that suits you better. You can even use one that the configuration is done inside the code. It's good to have choices, and there's a plenty out there.

Too many init systems

Any decent distribution let's you choose what init you want, and you use what is easy/better for you. Even so, most distributions that uses, let say, systemd, there's an alternative without it.

Too many tools

For what job? Some tools have alternatives, some with a lot of features but not everyone wants lots of features. For example, I like syslog-ng better for a syslog, but there's simple ones. 

Final thoughts

I understand, people that born limited are unable to understand how is "having choices". Maybe you don't want to choose, maybe you want that the world turns around you, maybe you want that everyone make the exact same choices as you. Maybe you should stick to windows and stop talking this bullshit everywhere. Or even better, move to some place that everyone is forced to do the same.

Preventing Lubuntu 18.04 from leaving a user process running after the user logs out

Fitzcarraldo
, 23/09/2019 | Source: Fitzcarraldo's Blog

My family’s desktop machine has Lubuntu 18.04 installed, which uses systemd and the LXDE desktop environment. Each family member has their own user account, thus the installation is a single-seat, multi-user installation. For each user’s account I set up the virus-checking scheme described in an earlier post, suitably modified to take into account the differences […]

How to run KDE Dolphin, Kate and KWrite as root user

Fitzcarraldo
, 19/09/2019 | Source: Fitzcarraldo's Blog

When using KDE I occasionally wish to launch KWrite or Kate as root user in order to edit system files more easily than using a TUI editor in a terminal window (either launched as root user or by using the sudoedit command). Being able to browse using Dolphin as the root user occasionally is also […]