#pyqt | Logs for 2019-03-13
Back
[01:15:03] -!- crmaurei has quit [Ping timeout: 245 seconds]
[01:15:30] -!- tijensse has quit [Ping timeout: 264 seconds]
[02:54:55] -!- saraf has joined #pyqt
[03:51:55] -!- saraf has quit [Ping timeout: 268 seconds]
[04:55:05] -!- crmaurei has joined #pyqt
[04:59:15] -!- n1` has joined #pyqt
[06:31:11] -!- BPL has joined #pyqt
[06:39:56] -!- n1` has quit [Quit: WeeChat 2.3]
[07:18:41] -!- n1` has joined #pyqt
[08:22:03] -!- nsizemor has joined #pyqt
[08:47:01] -!- Siecje has joined #pyqt
[11:23:39] -!- AbleBacon has joined #pyqt
[11:40:52] -!- n1` has quit [Ping timeout: 246 seconds]
[11:43:48] <Avaris> but why...? "Note: On macOS, the ControlModifier value corresponds to the Command keys on the keyboard, and the MetaModifier value corresponds to the Control keys."
[11:44:18] <altendky> Avaris: i thought mac tended to use the keys differently
[11:44:35] <altendky> it's command+c or such to copy
[11:46:08] <Avaris> sure but, there is literally a key called "control" and pressing it isn't ControlModifier.
[11:46:39] <altendky> Avaris: i mean i see the oddity but if you want the platform habits abstracted for you so you can just write code that works as expected everywhere...
[11:47:01] <altendky> it's gonna be a goofy looking lib when control means one thing on this os and something entirely else on another.
[11:47:16] <altendky> and a third thing on the second platform means the same as the first thing on the first platform
[11:48:24] <Avaris> i'm not gonna bother with a bunch of os.platform stuff, i'll just go with Alt instead :)
[11:48:48] <altendky> Avaris: i don't follow. (and isn't alt actually option?)
[11:49:23] <altendky> if you want a shortcut akin to copy, then use control. it'll be control on windows and linux and command on macos. (i think... i have it straight... maybe?)
[11:49:40] <Avaris> i have a tooltip saying "Control+Click: Do something". I'd have to check for macos and write "Command+Click" instead
[11:50:03] <altendky> i'd wonder if qt has a thing for generating the platform specific name for a shortcut
[11:51:05] <altendky> https://doc.qt.io
[11:51:20] <altendky> with QKeySequence::NativeText
[11:51:45] <Siecje> I don't use macOS often, but some things are still Ctrl like Ctrl+C
[11:52:10] <altendky> https://www.howtogeek.com
[11:52:20] <altendky> i mean i bet some programs don't cross platform properly...
[11:52:46] <altendky> though i also rarely use macos... hmm, i wonder if i ever actually have (as opposed to osx or original macos)
[11:59:20] <Avaris> oh geez, NativeText actually prints the command char
[12:05:21] <Avaris> and annoyingly you can't do QKeySequence('Ctrl'). you need to give actual key ('Ctrl+X' etc)
[12:05:38] <altendky> Avaris: do you not have it tied to a QAction already?
[12:06:00] <altendky> so you just relate to that and reuse it's key sequence
[12:06:36] <Avaris> it's not a keyboard shortcut. i have an item that can do 3 things on mouse click. Click: 1, Shift+Click: 2, Ctrl/Alt+Click: 3
[12:07:01] <altendky> hmm... you did say click, yes
[12:08:07] <altendky> maybe the source for the above function will yield something you can pass a modifier to directly
[12:11:53] <altendky> `Qt.QKeySequence.listToString(Qt.QKeySequence(Qt.Qt.KeyboardModifier.ControlModifier))` -> `'Ctrl+'` (in linux)
[12:12:25] <altendky> or `Qt.QKeySequence.listToString([Qt.Qt.KeyboardModifier.ControlModifier])`
[12:13:17] <Avaris> heh also `Ctrl+` on macOs
[12:13:24] * altendky sighs
[12:13:35] <altendky> err, with the native?
[12:14:34] <altendky> Qt.QKeySequence.listToString([Qt.Qt.KeyboardModifier.ControlModifier], Qt.QKeySequence.SequenceFormat.NativeText)
[12:14:47] <Avaris> ⌘
[12:14:55] <altendky> yay
[12:15:21] <Avaris> i'd prefer actual Command text but i guess i can use it
[12:16:23] <altendky> {'⌘': 'Command'}
[12:16:26] <altendky> :]
[12:18:44] <altendky> not sure that's a great idea though
[12:23:25] <Avaris> nah, left it as the special char. good enough :)
[12:23:54] <Avaris> thanks
[12:24:06] <altendky> Avaris: finally, i helped with something :]
[12:26:34] <Avaris> :)
[12:44:38] -!- kallesbar has quit [Ping timeout: 245 seconds]
[13:04:38] -!- BPL has quit [Quit: Leaving]
[13:26:44] -!- kallesbar has joined #pyqt
[14:46:28] -!- tyrathect has joined #pyqt
[14:47:38] -!- kallesbar has quit [Ping timeout: 250 seconds]
[14:57:03] -!- kallesbar has joined #pyqt
[15:29:50] -!- tyrathect has quit []
[15:55:00] -!- mintograde has joined #pyqt
[16:21:20] -!- kallesbar has quit [Quit: Konversation terminated!]
[16:27:55] -!- Siecje has parted #pyqt
[16:31:13] -!- nsizemor has quit [Quit: nsizemor]
[17:25:00] -!- n1` has joined #pyqt
[17:52:07] -!- n1` has quit [Ping timeout: 245 seconds]
[17:54:21] -!- n1` has joined #pyqt
[18:38:25] -!- n1` has quit [Ping timeout: 246 seconds]
[18:40:40] -!- n1` has joined #pyqt
[19:33:47] -!- n1` has quit [Ping timeout: 252 seconds]
[19:36:00] -!- n1` has joined #pyqt
[19:50:01] -!- AbleBacon has quit [Quit: Leaving]
[19:55:46] -!- n1` has quit [Ping timeout: 268 seconds]
[22:43:43] -!- mintograde has quit [Ping timeout: 252 seconds]
[22:53:09] -!- mandeep has joined #pyqt