08-01-2021, 05:26 PM | #16 |
Guru
Posts: 856
Karma: 2676800
Join Date: Aug 2008
Location: Taranaki - NZ
Device: Kobo Aura H2O, Kobo Forma
|
Don't forget, Nickel is old. I imagine it still carries a lot of baggage from its Qt 4.6 days, despite the fact they're now using Qt 5.2.
As far as styling goes, geek1011 was (I think) referring to stuff like font face and size, as well as border styles etc. Unstyled widgets on Kobo's are... not pretty. |
08-02-2021, 12:33 AM | #17 |
Guru
Posts: 856
Karma: 2676800
Join Date: Aug 2008
Location: Taranaki - NZ
Device: Kobo Aura H2O, Kobo Forma
|
I've done some experimenting today, and managed to subclass a QPushButton and respond to standard QGesture events. Or at least tap events.
|
Advert | |
|
08-03-2021, 09:31 AM | #18 |
Junior Member
Posts: 8
Karma: 10
Join Date: Jul 2021
Device: Kobo Libra H2O
|
Which signals were you able to see when using a standard widget?
I've not played much more as I've been tidying up how my symbols work, the C code was bugging me some what but now I have an `IconButton` class that behaves as a QObject so I can create a button like a Qt class without passing things into functions (pretty much a shim on top of the NickelHook symbols). With that and some playing around with the Nickel GenericContainer I've been able to inject some new buttons into the `More` menu. |
08-03-2021, 05:23 PM | #19 |
Guru
Posts: 856
Karma: 2676800
Join Date: Aug 2008
Location: Taranaki - NZ
Device: Kobo Aura H2O, Kobo Forma
|
I've been doing some more experimenting and it appears there's at least some support for QTouchEvent as well, if enabled by setting Qt::WA_AcceptTouchEvents attribute on a widget.
I've only ever seen TouchBegin events though. And I've discovered that Qt gestures are a PITA |
11-17-2023, 01:20 AM | #20 |
Enthusiast
Posts: 26
Karma: 78045
Join Date: Oct 2023
Location: Ontario, Canada
Device: Kobo Aura Edition 2, Kobo Clara 2E
|
Hello everyone,
Would it be possible for you, any of you, to share a symdump or something similar to help with workong on libnickel in Ghidra? As a decompilation novice, I would take any help I could get to develop mods. Thanks! |
Advert | |
|
11-17-2023, 09:51 AM | #21 |
Wizard
Posts: 2,735
Karma: 6990705
Join Date: May 2016
Location: Ontario, Canada
Device: Kobo Mini, Aura Edition 2 v1, Clara HD
|
All the symbols you'll get are in libnickel itself, and should work with most tools. The only other information is the Qt metaobject stuff (see the NickelDBus-related stuff for more about that), and the C++ RTTI. For tail call address extraction, use my symdump tool in the Kobo patch repo. For Qt resources, use my qrc tool, or look in the kobopatch firmware release issues on GitHub.
|
11-27-2023, 10:40 PM | #22 | ||
Enthusiast
Posts: 26
Karma: 78045
Join Date: Oct 2023
Location: Ontario, Canada
Device: Kobo Aura Edition 2, Kobo Clara 2E
|
Thank you @geek1011.
I am making slow progress but I think I'm at a point where I can ask a few questions. I'm having trouble getting hooks to be established. dlsym grabs are working fine. Here's how I'm configuring. If I have only the following: Quote:
But, when I switch to a hook instead with the following, my init doesn't work anymore. Quote:
Thanks |
||
11-27-2023, 11:27 PM | #23 |
Wizard
Posts: 2,735
Karma: 6990705
Join Date: May 2016
Location: Ontario, Canada
Device: Kobo Mini, Aura Edition 2 v1, Clara HD
|
Try adding this after the extern C: __attribute__((visibility("default")))
|
11-27-2023, 11:58 PM | #24 |
Enthusiast
Posts: 26
Karma: 78045
Join Date: Oct 2023
Location: Ontario, Canada
Device: Kobo Aura Edition 2, Kobo Clara 2E
|
|
11-28-2023, 12:58 AM | #25 |
Wizard
Posts: 2,735
Karma: 6990705
Join Date: May 2016
Location: Ontario, Canada
Device: Kobo Mini, Aura Edition 2 v1, Clara HD
|
I'll take a closer look at it later this week if nobody gets to it first.
Do any log lines appear in the syslog at all? |
11-28-2023, 11:14 AM | #26 |
Enthusiast
Posts: 26
Karma: 78045
Join Date: Oct 2023
Location: Ontario, Canada
Device: Kobo Aura Edition 2, Kobo Clara 2E
|
Thank you.
I've published the complete code here at this repository as well. https://github.com/onatbas/nickelnote.git I'm not seeing any logs. I used to get NickelNote_<TIMESTAMP>.txt files generated in the .adds folder when I was setting up the system; I saw fatal errors get captured, but that was an earlier issue. Now, with this one, I'm not getting any files. I don't have syslog in its usual place (I checked /var/log/syslog and syslog. conf). Is that in a different spot on a kobo? "find / | grep log" doesn't yield anything useful either. |
11-28-2023, 12:57 PM | #27 | |
Enthusiast
Posts: 26
Karma: 78045
Join Date: Oct 2023
Location: Ontario, Canada
Device: Kobo Aura Edition 2, Kobo Clara 2E
|
I've managed to get some logs, it looks like it fails to find the symbol.
Quote:
|
|
11-28-2023, 11:13 PM | #28 |
Wizard
Posts: 2,735
Karma: 6990705
Join Date: May 2016
Location: Ontario, Canada
Device: Kobo Mini, Aura Edition 2 v1, Clara HD
|
It's the "logread" command, btw.
The symbol error is coming from the OverDriveActionProxy one. I'll check in an hour or two. |
11-29-2023, 08:20 PM | #29 |
Wizard
Posts: 2,735
Karma: 6990705
Join Date: May 2016
Location: Ontario, Canada
Device: Kobo Mini, Aura Edition 2 v1, Clara HD
|
I don't see anything obviously incorrect about the code, but do note that you'll want to include the Makefile in the repository. Also, on a side note, the overdrive thing you're doing is better suited as a patch than a hook, though a hook should work fine (I'd hook the getter personally, though).
|
11-29-2023, 11:01 PM | #30 |
Enthusiast
Posts: 26
Karma: 78045
Join Date: Oct 2023
Location: Ontario, Canada
Device: Kobo Aura Edition 2, Kobo Clara 2E
|
Thanks for checking it. The Makefile is unchanged from what nickelhook generates. I'll commit that, too.
I tried with many other symbols, and I don't seem to be able to hook anything. I will check the ways of implementing it (along with a few other mods I'm planning based on Nickelhook). I didn't see the getter, hah! I can recompile nickelclock using the same setup, and it works. I used your symdump to ensure the symbols are in place; they are. I checked the NickelHook versions between various projects; the only difference is the readme between my version and others. I'll try uninstalling all other things and check again. |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Kindle Touch] Calibre Kindle Collections Plug-in Hooks | sumpin | Kindle Developer's Corner | 68 | 11-30-2012 06:20 PM |
Finding my posts | melmac | Feedback | 5 | 08-30-2011 02:34 PM |
Need help finding an e-reader please | Pica | Which one should I buy? | 28 | 12-19-2010 09:26 AM |
Hooks, They Ain't That Easy | plumboz | Writers' Corner | 8 | 05-03-2010 08:28 PM |
Need help finding this book | Katosen | Reading Recommendations | 5 | 09-10-2009 09:42 PM |