One year ago it was Twos-Day Tuesday.
https://youtu.be/Ffa8-S_71xo
https://youtu.be/267MQF1z2PU
https://youtu.be/2XKuG7cA03A
#links #video #youtube
https://youtu.be/Ffa8-S_71xo
https://youtu.be/267MQF1z2PU
https://youtu.be/2XKuG7cA03A
#links #video #youtube
YouTube
Twos-Day Tuesday! 22 YouTubers celebrate all things "two" and nothing goes wrong.
Happy Twos-Day Tuesday! Please donate to WaterAid using the fundraising link on this video or direct at https://www.wateraid.org/ It's ridiculous that in 2022 not every human can go for a safe and sanitary number two.
Continue this video on Steve Mould Shorts:…
Continue this video on Steve Mould Shorts:…
For years have I been struggling with non-functional tooltips (
And I've fixed it with a simple #Stylus global style:
#css #html #firefox #mobile
<abbr title>) in mobile browsers.And I've fixed it with a simple #Stylus global style:
[title]:hover::after {
display: inline;
position: absolute;
background: #ffd4c9;
color: black;
border: 1px solid black;
padding: 1px;
border-radius: 2px;
content: attr(title);
}#css #html #firefox #mobile
Vftdan Channel
For years have I been struggling with non-functional tooltips (<abbr title>) in mobile browsers. And I've fixed it with a simple #Stylus global style: [title]:hover::after { display: inline; position: absolute; background: #ffd4c9; color:…
userstyles.world
Tooltips on android by vftdan
Implement title attribute display as a tooltip on mobile devices on hover by using ::after pseudoelement.
🔥1
I was asked to share my quote collection. So here it is:
https://docs.google.com/document/d/1OtM5dlTUqMiu5zJBkIVlYLTQKQGas2BwAyiW4r3YuWI/edit?usp=drivesdk
Mostly in English and Russian.
https://docs.google.com/document/d/1OtM5dlTUqMiu5zJBkIVlYLTQKQGas2BwAyiW4r3YuWI/edit?usp=drivesdk
Mostly in English and Russian.
Google Docs
Quotes
“В чем проблема? Да в том, что stdout там человеко-читаемый, то есть программно его хрен разберешь.” src: https://t.me/nikitonsky_pub/209 “Показатель порождает показуху” src: “Компьютер, он не резиновый, абстракции протекают, а сложность не складывается…
👍1
Cool channel
https://www.youtube.com/@TodePond/
Chill videos, mostly about a cellular automaton -based falling-sand game, but sometimes about other nerdy stuff.
#links #youtube
https://www.youtube.com/@TodePond/
Chill videos, mostly about a cellular automaton -based falling-sand game, but sometimes about other nerdy stuff.
#links #youtube
❤2
How to fix Haskell code full of errors like
Add
and add the minimal relevant
This should help to find the exact problem source.
Couldn't match type ‘f1’ with ‘f’:Add
{-# LANGUAGE ScopedTypeVariables #-}
(and probably {-# LANGUAGE InstanceSigs #-} if the problem is with typeclass instance implementation)and add the minimal relevant
forall for every type declaration.This should help to find the exact problem source.
xkb to xkm compilation:
In a
Shift level is an integer. There can be up to 63 shift levels:
(source:
Shift level inside xkb file is parsed as an integer:
(source: https://gitlab.freedesktop.org/xorg/app/xkbcomp/-/blob/master/keytypes.c#L815 )
Integers will most likely (for this exact purpose) be written a value token (
or as an identifier token (
In the case of shift levels it's a simple lookup (apparently, it's case-insensitive) inside a
...
(source: https://gitlab.freedesktop.org/xorg/app/xkbcomp/-/blob/master/keytypes.c#L638 )
Instead of a magic number (something like
But levels 9–63 don't have corresponding identifiers, so they must be written as numeric literals.
xkb from xkm decompilation:
Just printf's lines for
(source: https://gitlab.freedesktop.org/xorg/lib/libxkbfile/-/blob/master/src/xkbout.c#L239 )
This creates invalid xkb files, if there are shift levels 9–63 used inside at least one of the key types of the keymap.
--------
My keymap has additional key types, one of them has 16 shift levels.
Apparently, Xorg xserver decompiles the keymap that the user has loaded inside it and recompiles it again and, at least on failures, tries to compile it again (like every second or every key press).
This floods my Xorg log with this message about failed invocation of the compiler:
In a
type block inside the xkb_types section expects shift level on the left-hand-side (as an index) of map entries and on the right-hand-side of level_name entries.Shift level is an integer. There can be up to 63 shift levels:
#define XkbMaxShiftLevel 63
(source:
/usr/include/X11/extensions/XKB.h line 560)Shift level inside xkb file is parsed as an integer:
if (!ExprResolveInteger(arrayNdx, &rtrn, SimpleLookup, (XPointer) lnames))
return ReportTypeBadType(type, "level name", "integer");
(source: https://gitlab.freedesktop.org/xorg/app/xkbcomp/-/blob/master/keytypes.c#L815 )
Integers will most likely (for this exact purpose) be written a value token (
ExprValue) of integer type (TypeInt); (source: https://gitlab.freedesktop.org/xorg/app/xkbcomp/-/blob/master/expr.c#L599 )or as an identifier token (
ExprIdent), in this case it's numeric value is looked up with a given function in given object. (source: https://gitlab.freedesktop.org/xorg/app/xkbcomp/-/blob/master/expr.c#L628 )In the case of shift levels it's a simple lookup (apparently, it's case-insensitive) inside a
LookupEntry array named lnames. This array has entries for levels from 1 to 8, and correspond to a string "level" prepended to their decimal representation:static LookupEntry lnames[] = {
{"level1", 1},...
{"level8", 8},
{NULL, 0}
};(source: https://gitlab.freedesktop.org/xorg/app/xkbcomp/-/blob/master/keytypes.c#L638 )
Instead of a magic number (something like
level_name[8] = "Shift Level3+Alt";) xkb files will most likely have identifier names (level_name[Level8] = "Shift Level3+Alt";) (probably for human-readability reasons).But levels 9–63 don't have corresponding identifiers, so they must be written as numeric literals.
xkb from xkm decompilation:
Just printf's lines for
map and level_name entries while adding "Level" to the decimal representation of the shift level numeric value:fprintf(file, " level_name[Level%d]= \"%s\";\n", n + 1,
XkbAtomText(dpy, *name, XkbXKBFile));
(source: https://gitlab.freedesktop.org/xorg/lib/libxkbfile/-/blob/master/src/xkbout.c#L239 )
This creates invalid xkb files, if there are shift levels 9–63 used inside at least one of the key types of the keymap.
--------
My keymap has additional key types, one of them has 16 shift levels.
Apparently, Xorg xserver decompiles the keymap that the user has loaded inside it and recompiles it again and, at least on failures, tries to compile it again (like every second or every key press).
This floods my Xorg log with this message about failed invocation of the compiler:
(EE) Error compiling keymap (server-0) executing '"/usr/bin/xkbcomp" -w 1 "-R/usr/share/X11/xkb" -xkm "-" -em1 "The XKEYBOARD keymap compiler (xkbcomp) reports:" -emp "> " -eml "Errors from xkbcomp are not fatal to the X server" "/var/lib/xkb/server-0.xkm"'And my display manager log — with compiler error messages:
(EE) XKB: Couldn't compile keymap
The XKEYBOARD keymap compiler (xkbcomp) reports:...
> Error: Identifier "Level9" of type int is unknown
> Error: Level specifications in a key type must be integer
> Ignoring malformed level specification
> Error: Identifier "Level16" of type int is unknown
> Error: The key type level name field must be a integer
> Ignoring illegal assignment in PC_LEVEL3_ALT_CONTROL_16LEVELS
Errors from xkbcomp are not fatal to the X server
GitLab
keytypes.c · master · xorg / app / xkbcomp · GitLab
XKB keyboard description compiler
POSIX shell encourages to write pure functions, because they can be called from subshells.
❤2🤔1
Vftdan Channel
Goodbye, 131-day uptime
And also goodbye 574-day phone uptime. Ran out of charge yesterday evening while working as a hotspot in a meter from me. Apparently, KDE Connect hasn't established connection to notify me that the phone was low.
😢2
Forwarded from 0xFABC0FFEEBADC0DE
My dudes, I might have solved the yesterday vs. today problem. Caution: shameless word coinage incoming!
Introducing: "yestoday" — the last day that technically already passed, but it still doesn't feel like the following day has started (e.g. one hasn't been to bed yet).
Usage example: "I'm afraid I can't complete this task yestoday."
Introducing: "yestoday" — the last day that technically already passed, but it still doesn't feel like the following day has started (e.g. one hasn't been to bed yet).
Usage example: "I'm afraid I can't complete this task yestoday."
❤2