https://www.xltoolbox.net/Daniel's XL Toolbox Developer Blog2018-08-24T05:38:04ZDaniel Kraushttp://www.bovender.dehttp://xltoolbox.net/img/design/logo_small.pnghttp://xltoolbox.net/img/design/banner-paypal.pngtag:www.xltoolbox.net,2018-08-24:/blog/2018/08/exit-thinkpad-t430s-enter-thinkpad-t480s.htmlExit ThinkPad T430s, enter ThinkPad T480s2018-08-24T05:38:04Z2018-08-24T05:38:04Z <div class="blog-image text-center">
<img class="img-responsive center-block" src="/img/blog/2018/08/thinkpad-top.jpg" alt="thinkpad-top.jpg">
<div class="text-muted text-center caption"></div>
</div>
<p>I recently purchased a new laptop. My old Thinkpad T430s had come of age.
Its keyboard fell apart, its body had a crack (after a fall), and the hard
drive was full. These are all things that can be taken care of, especially
with a Thinkpad. However, my old machine was 5 years old, so I decided to
get an upgrade.</p>
<p>This is my subjective review of the Thinkpad T480s, compared with the old
T430s that was my daily workhorse.</p>
<h2 id="deciding-on-a-thinkpad-model">Deciding on a Thinkpad model</h2>
<p>I went for the T480s rather than the X1 Carbon 6th because it has faster
RAM (2400 vs. 2133 MHz), a built-in SD card reader (rather than a microSD
reader), and higher-resolution, matte screen. It did not matter to me so
much that the T480s is slightly larger and heavier (1.3 vs. 1.1 kg) than
the X1 Carbon.</p>
<p>Most T480s configurations come with Intel integrated graphics, but there’s
also one with dedicated graphics (NVidia) available. Just like with my old
T430s, I chose the integrated graphics version in order to have less heat
generated, expecting that I would not need the extra power of a dedicated
graphics solution 99% of the time.</p>
<p>My system has extra RAM and a high-end solid-state drive, both of which
are really handy when it comes to building software. In addiiton, I’ve had
some scientific computations in R that used all of the 16 GB as well as
swap space of my T430s, so the additional 8 GB in the new model may be
useful for scientific work as well.</p>
<h2 id="comparison-of-specs-old-vs-new">Comparison of specs, old vs. new</h2>
<table>
<thead>
<tr>
<th> </th>
<th>T430s 2356-AB2</th>
<th>T480s 20L8S02D00</th>
</tr>
</thead>
<tbody>
<tr>
<td>Year</td>
<td>2013</td>
<td>2018</td>
</tr>
<tr>
<td>CPU</td>
<td>i5-3320M (3 MB, 15 W)</td>
<td>i5-8250U (6 MB, 15 W)</td>
</tr>
<tr>
<td>GPU</td>
<td>Intel HD 4000</td>
<td>Intel UHD 620</td>
</tr>
<tr>
<td>RAM</td>
<td>16 GB 1600 MHz</td>
<td>24 GB 2400 MHz</td>
</tr>
<tr>
<td>Display</td>
<td>1600x900, TNT</td>
<td>2560x1440, IPS</td>
</tr>
<tr>
<td>Hard drive</td>
<td>512 GB Samsung 840 Pro</td>
<td>1 TB Samsung 970 Pro NVMe</td>
</tr>
<tr>
<td>Size</td>
<td>343 x 240 x 21-26 mm</td>
<td>331 x 227 x 17 mm</td>
</tr>
<tr>
<td>Weight</td>
<td>1.8 kg (4 lb)</td>
<td>1.3 kg (2.9 lb)</td>
</tr>
</tbody>
</table>
<h2 id="compatibility-with-linux">Compatibility with Linux</h2>
<p>Installing KDE neon 5.13 (with KDE Plasma 5.13.4) was a breeze. The
installation from a USB 3.0 thumb drive took just a few minutes. The
subsequent customization did not require a lot of manual work, thanks to
my <a href="https://www.ansible.com">Ansible</a> scripts. All my data and files were
transferred using a link-local ethernet cable and rsync, which was
extremely fast.</p>
<p>The hardware is supported out of the box. At the time of writing, KDE neon
5.13 uses kernel version 4.15.0. The built-in speakers, microphone and
webcam require absolutely no setup. It should also go without saying that
WiFi and bluetooth just work. I did have some trouble getting the WWAN
modem (4G) to work, but that was because ModemManager is not started
automatically by KDE neon. A simple <code>sudo systemctl start ModemManager</code>
solved this.</p>
<p>I have not tried to use the fingerprint reader. It appears that it is
<em>not</em> currently supported; see the <a href="https://wiki.archlinux.org/index.php/Lenovo_ThinkPad_T480s">Arch
wiki</a> and this
<a href="https://www.reddit.com/r/thinkpad/comments/86ln8u/t480_fingerprint_scanner_linux_driver_how_to">Reddit
thread</a>.</p>
<p>The high resolution of the Thinkpad’s IPS panel is great, it’s much more
pleasant to read PDF articles for example, but the window controls and
labels <em>are</em> very tiny at 2560x1440 pixels on a 14 inch screen. Luckily,
nowadays you can scale the display, and scaled by 1.3 I no longer have to
squint. Unfortunately, it turns out that the scale factor applies to <em>all</em>
screens attached to the system, so that my 25” WQHD display now has very
large letters. I tried out an experimental (?) Plasma session on Wayland,
which supports individual scale factors for each display, but right now
Wayland can only scale with integers – and 2x scaling is a bit too much…
Evidently fractional scaling is under way at least for the Gnome desktop
(<a href="https://www.omgubuntu.co.uk/2017/09/enable-fractional-scaling-gnome-linux">see the OMG!Ubuntu article on that
topic</a>),
but not yet in KDE Plasma/KWin. For me, the lack of support for multiple
displays with varying pixel density is the only hardware compatibility
issue that I have, running KDE neon on my new Thinkpad T480s.</p>
<h3 id="getting-the-lenovo-thunderbolt-dock-to-work">Getting the Lenovo Thunderbolt Dock to work</h3>
<p>Along with the Thinkpad I obtained a Lenovo Thunderbolt dock to replace
the old ultra dock that used to sit on my desk. The Thunderbolt dock is a
neat little box that makes for a much tidier desk than the old-school
ultra dock which was rather clumsy, in my opinion. My wife uses the
Thunderbolt dock with an X1 Carbon 5th without problems, so I did not
expect the T480s to cause me any trouble here.</p>
<p>To my great surprise, the first attempt to use an extrenal screen and
external hard drives with the Thunderbolt dock failed. They just were not
detected by the Thinkpad. Even when I changed the primary display to
‘external’ in the Thinkpad’s BIOS settings, the screen remained black.</p>
<p>The solution for this turned out to be dead simple. There are two
Thunderbolt ports on the left side of the T480s. I had connected the
Thunderbolt cable to the left one, i.e. the one where one would normally
also plug the power cord (which has a USB-C connector).</p>
<div class="blog-image text-center">
<img class="img-responsive center-block" src="/img/blog/2018/08/thunderbolt-ports.jpg" alt="thunderbolt-ports.jpg">
<div class="text-muted text-center caption"></div>
</div>
<p>As soon as I connected the dock to the right one of the two ports (no pun
intended), it finally worked! :-)</p>
<p>While fumbling to get the dock work, I had relaxed the Thunderbolt
security settings, which I think is necessary to get it to work with
Linux. However, I have not formally tested this. <a href="https://help.gnome.org/misc/release-notes/3.28">GNOME
3.28</a> supports <a href="https://www.omgubuntu.co.uk/2017/12/project-bolt-improves-thunderbolt-security-linux">user
settings for Thunderbolt
security</a>
with ‘Bolt’, but such a feature has not (yet?) been implemented in KDE
Plasma.</p>
<p>Here are two screenshots of my Thunderbolt-related BIOS settings.
Actually, the first screenshot only shows how to get to the Thunderbolt
sub-menu.</p>
<div class="blog-image text-center">
<img class="img-responsive center-block" src="/img/blog/2018/08/setup-config.jpg" alt="setup-config.jpg">
<div class="text-muted text-center caption"></div>
</div>
<div class="blog-image text-center">
<img class="img-responsive center-block" src="/img/blog/2018/08/setup-tb.jpg" alt="setup-tb.jpg">
<div class="text-muted text-center caption"></div>
</div>
<h2 id="what-i-like-better-about-the-t480s-vs-the-t430s">What I like better about the T480s vs. the T430s</h2>
<ul>
<li>It is considerably less noisy than the T430s. The fan stays off most of
the time (but see note about the sound of the fan below).</li>
<li>The IPS screen is way better than the T430s’ display.</li>
<li>It is noticeably lighter.</li>
<li>The keyboard is a bit more pleasant to type on. The T430s’ keyboard was
good already, just like the keyboards of the R50p and the T61 that I
previously owned, but the T480s has the best Thinkpad keyboard I have
yet typed on.</li>
</ul>
<h2 id="what-i-dislike-about-the-t480s">What I dislike about the T480s</h2>
<p>The new T480s also has a few drawbacks compared with the old T430s:</p>
<ul>
<li>No dedicated hardware keys for speakers and microphone. You have to use
a combination of keys with the <kbd>Fn</kbd> key. On the T430s, I loved
how you could silence the machine just with a press of the index finger,
which works well even when you are on the phone or are doing other
stuff. Silencing the machine is a bit less straight-forward now.</li>
<li>No LED indictors for power state, wireless, and hard drive access. These
indicators were very handy to immediately assess whether the machine was
busy or not. Of course this can be done by software with KDE widgets,
for example. Still, I liked the built-in indicators better. Especially
since one could also assert whether the machine was running or in
standby or charging while it was closed, because there were LED
indicators on the outside as well. Now there’s a stylish LED in the ‘i’
of the Thinkpad badge (see photo at the top). It pulses when the machine
is in standby, but it takes a couple of seconds to determine whether it
is constantly on, constantly off, or pulsing.</li>
<li>Absence of a hardware switch for all radios. There are situations where
I want to make sure that the Thinkpad is not doing anything over the
air, and the T430’s hardware switch was very useful in that regard.</li>
<li>The fan has a terrible pitch. Luckily the fan stays off most of the
time, but once it’s on, its high-pitched sound is a pain in the… ear.</li>
<li>I really don’t like that the power cord is attached on the left side of
the laptop. The T430s had the power connector at the back, where it does
not hinder my work. With the cable sticking out on the left side, I
have to make a loop if the power outlet is to the right of the laptop;
it gets in the way when I charge the laptop inside my office bag; and so
on.</li>
</ul>
<h2 id="conclusion">Conclusion</h2>
<p>All in all, the T480s is a fine machine and a good replacement for the
T430s. However, given that there are 5 years of development between the
two models, I must say that I am a little underwhelmed. Maybe that’s
because the T430s was such a sturdy machine in the first place. The two
most welcome improvements with the T480s are the high-resolution IPS
screen and the lower weight, I guess. The performance of the Samsung 970
Pro NVMe “disk” is not really that much better than the old 840 Pro SATA,
but maybe the benefits will show once I do a bit more photo editing and,
of course, programming and compiling.</p>
My experience with my new T480s, coming from a T430s that served me very well for the past 5 years.
tag:www.xltoolbox.net,2018-07-26:/blog/2018/07/linux-and-virtualbox-on-a-t480s-with-high-resolution-display.htmlLinux and VirtualBox on a T480s with high-resolution display2018-07-26T14:33:16Z2018-07-26T14:33:16Z<p>My new Thinkpad T480s has a 14” high-resolution WQHD display with a
resolution of 2560 &mult; 1440 pixels. It looks great. PDF files display
super crisp. Programming with lots of different panels and windows, and
data analysis with large tables is so much easier than with low-resolution
displays that require a lot of scrolling.</p>
<p>I must admit though that any text that the operating system (KDE neon,
for what it’s worth) displays is really, really tiny. Luckily, modern
operating systems offer an option to scale a display, what I did. A
scaling factor of 1.5 is a good compromise between the amount of
information that is displayed, and its readability.</p>
<p>There turned out to be one problem with my Windows guest running in a
VirtualBox machine: The guest operating system looked all blurry.</p>
<p>Luckily, there is an option to force VirtualBox to not attempt and scale
the guest. Prefix the command with</p>
<pre><code>export QT_AUTO_SCREEN_SCALE_FACTOR= QT_SCREEN_SCALE_FACTORS= QT_SCALE_FACTOR=
</code></pre>
<p>and you’re all set.</p>
<p>To make this permanent, I added this to my <code>.desktop</code> file:</p>
<pre><code># ~/.local/share/applications/Win7prod.desktop
[Desktop Entry]
Version=1.0
Name=Win7 (Production)
Comment=Starts the VirtualBox machine Win7prod
Type=Application
Exec=env QT_AUTO_SCREEN_SCALE_FACTOR= QT_SCREEN_SCALE_FACTORS= QT_SCALE_FACTOR= /usr/lib/virtualbox/VirtualBox --comment "Win7prod" --startvm "Win7prod"
Icon=/home/daniel/local/Pictures/Icons/win7.svg
</code></pre>
<p>Note the <code>env</code> command in the <code>Exec</code> line!</p>
<p>Hat tip to <a href="https://www.virtualbox.org/ticket/15765#comment:6">https://www.virtualbox.org/ticket/15765#comment:6</a></p>
High-resolution (HiDPI) displays can cause all sorts of trouble. Here's how I solved mine.tag:www.xltoolbox.net,2018-05-03:/blog/2018/05/what-i-like-and-dislike-about-ubuntu-18-dot-04.htmlWhat I like and dislike about Ubuntu 18.042018-05-03T03:53:31Z2018-05-03T03:53:31Z<p>Ubuntu 18.04 is out, and similarly to 17.10, there are a couple of things
that I <a href="/blog/2017/10/what-i-dislike-about-ubuntu-17-dot-10.html">like and
dislike</a> about
it.</p>
<!-- -->
<p>Interestingly, I get the impression that there are more and more things
that I <em>dislike</em> about new iterations of my favorite Linux distribution.
Whatever that means for the future. Frankly, I’ve considered trying
Kubuntu… But for, now, I’ll stick with Ubuntu and the good ol’ Unity
desktop. I do switch to Gnome every now and then on login, but I always
return to Unity.</p>
<p>The following list is by no means exhaustive. I may update it from time to
time.</p>
<h2 id="like">Like</h2>
<h2 id="dislike">Dislike</h2>
<ul>
<li>
<p>On my Thinkpad T430s, the trackpoint is way too fast with 18.04. All
worked well with previous versions of Ubuntu. Can’t set the speed in the
graphical applet any more. <a href="https://askubuntu.com/a/611076/115231">An AskUbuntu
answer</a> by @Akiva came to my
rescue (although the intention in that AskUbuntu answer was to make the
Trackpoint <em>more</em> responsive, not less).</p>
<p><a href="https://askubuntu.com/a/689741/115231">This</a> might be an alternative
solution, haven’t tried it.</p>
</li>
<li>
<p><code>pdftk</code> is no longer available in Ubuntu!!! Now that’s a major problem.
I use this tool very often. Seems there is a <a href="https://askubuntu.com/a/1028983/115231">fairly simple
way</a> to
manually build and install it, need to try it.</p>
</li>
</ul>
<h2 id="addendum-26-jul-2018">Addendum (26 Jul 2018)</h2>
<p>I never really got used to Ubuntu 17.10 or 18.04. GNOME is not for me, and
now that I knew that Unity would likely never get its bugs fixed, I
started to look around for alternatives.</p>
<p><a href="https://neon.kde.org">KDE neon</a> is now my preferred system.</p>
<p>The last time that I tried the KDE desktop was in the early 2000s…
Today’s Plasma desktop (5.13) is an entirely different experience. While
not entirely free of bugs, those few bugs that did nag me in the past
couple of weeks were usually fixed very quickly by the KDE team. Kudos!</p>
<p>In my opinion, KDE Plasma is the go-to desktop environment for power users
who don’t feel like taking the time and configure a real power-user window
manager such as <a href="https://awesomewm.org">awesome</a> or
<a href="https://i3wm.org">i3</a>.</p>
Ubuntu 18.04 is out, and similarly to 17.10, there are a couple of things
that I like and
dislike about
it.tag:www.xltoolbox.net,2017-10-18:/blog/2017/10/what-i-dislike-about-ubuntu-17-dot-10.htmlWhat I like and dislike about Ubuntu 17.102017-10-18T18:01:25Z2017-10-18T18:01:25Z<p>The release of Ubuntu 17.10 marks (yet another) paradigm shift in the
development history of this Linux distribution. The home-grown Unity
desktop shell is gone; Ubuntu 17.10 offers a Ubuntu-flavored Gnome desktop
experience. This article lists my impressions with Ubuntu 17.10. It’s
really mostly negative impressions, but some things are better than with
Ubuntu 17.04. May it help others make the decision whether to upgrade to
17.10 or not.</p>
<!-- -->
<p>This post will probably be updated over time.</p>
<h3 id="screenshots">Screenshots</h3>
<ul>
<li>Shutter does not work with Ubuntu 17.10, which uses the new Wayland
display server instead of the old X.org server. Gnome-screenshot, which
comes with Gnome, is rather clumsy. Or I’m too clumsy for
gnome-screenshot. I take a lot of screenshots. You can of course take
screenshots and have them copied to the clipboard with keyboard
shortcuts (see screenshot ;-) below), but it’s not the same as with
Shutter.</li>
</ul>
<p><img src="/img/blog/2017/10/screenshot-shortcuts.png" alt="Screenshot shortcuts" /></p>
<h3 id="nautilus-files">Nautilus (Files)</h3>
<ul>
<li>Lack of type-ahead search. Ubuntu used to have a patched version of
Nautilus that added this feature, but the version included in Ubuntu
17.10 is not patched.</li>
</ul>
<h3 id="windows">Windows</h3>
<ul>
<li>Modal dialogs are attached to the parent window and cannot be moved.
What a nuisance! When I save a PDF file of a scientific article, I often
have to move the file dialog out of the way to see the article’s first
author’s name. Impossible with the default setting. Luckily, this
behavior can be changed with the Tweak tool.</li>
<li>Ubuntu used to be very efficient with screen real estate. Ubuntu 17.10
(Gnome desktop) takes away vertical space with a window title bar that
used to integrate nicely with the desktop title bar.</li>
<li>Buttons are all over the place. The application menu is invoked from a
button in the bottom-left. Window control buttons (minimize, maximize,
close) are now on the top-right again. The menu is on the top-left with
some applications; top-right with others.</li>
</ul>
<p><img src="/img/blog/2017/10/ubuntu-17-10-controls.png" alt="Controls in Ubuntu 17.10" /></p>
<p>In Ubuntu 17.04, everything used to be in the top-right corner:</p>
<p><img src="/img/blog/2017/10/ubuntu-17-04-controls.png" alt="Controls in Ubuntu 17.04" /></p>
<h3 id="miscellaneous">Miscellaneous</h3>
<ul>
<li>When a USB drive is plugged in, there is no icon in the Ubuntu dock.</li>
<li>No icon for the Telegram messenger in the title bar.</li>
</ul>
<h2 id="a-couple-of-things-that-i-like-better-in-ubuntu-1710-than-in-older-versions">A couple of things that I like better in Ubuntu 17.10 than in older versions</h2>
<ul>
<li>Notifications on the lock screen a kinda neat.</li>
<li>Ability to see recent notifications by clicking on the time in the title
bar.</li>
<li>Application (activities) launcher appears much faster than the Unity
launcher in Ubuntu 17.04.</li>
</ul>
The release of Ubuntu 17.10 marks (yet another) paradigm shift in the
development history of this Linux distribution. The home-grown Unity
desktop shell is gone; Ubuntu 17.10 offers a Ubuntu-flavored Gnome desktop
experience. This article lists my impressions with Ubuntu 17.10. It’s
really mostly negative impressions, but some things are better than with
Ubuntu 17.04. May it help others make the decision whether to upgrade to
17.10 or not.tag:www.xltoolbox.net,2017-07-19:/blog/2017/07/getting-phatch-to-work-on-ubuntu-17-dot-04.htmlGetting Phatch to work on Ubuntu 17.042017-07-19T17:09:00Z2017-07-19T17:09:00Z<p><a href="http://photobatch.wikidot.com">Phatch</a> is a fantastic tool to process a large number of photos in the
same manner. For example, I use it to shrink images to show on a digital
picture frame. Unfortunately it has not been maintained for years, and it
will not start on recent versions of Ubuntu. Here’s a workaround.</p>
<!-- -->
<p>To make Phatch start again, edit the file <code>wxPil.py</code>:</p>
<pre><code>$ sudo vim /usr/share/phatch/phatch/lib/pyWx/wxPil.py
</code></pre>
<p>Find line 44 (press <code>44G</code> in Vim) and append <code>.Get()</code>:</p>
<pre><code>size = wx_image.GetSize().Get()
</code></pre>
<p>Source: <a href="http://forums.debian.net/viewtopic.php?f=10&t=130880#p633146">Debian
forums</a>.</p>
<p>I post this here so I can find it easily if I have to re-install my
system. Maybe it helps others too.</p>
Phatch is a fantastic tool to process a large number of photos in the
same manner. For example, I use it to shrink images to show on a digital
picture frame. Unfortunately it has not been maintained for years, and it
will not start on recent versions of Ubuntu. Here’s a workaround.