-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Firmware 4.23.15505 main navigation changes #78
Comments
NickelMenu is still safe to use, but the main menu items won't appear anymore. In addition, at least To put back support for the main menu, I can either turn the new clock which replaced it into a new menu, or I can add to the "More" tab, or both. I haven't decided whether I'm going to release this as I will be testing most changes on |
After a preliminary look at libnickel, I think it's more likely that I'm going to add another button to the bottom nav rather than adding items to the More menu itself. It appears to be safer and easier to hook, plus it'll be easier to use and there's enough empty space for another button (which would even make it look nicer IMO). I haven't looked into the option of replacing the clock yet. The main disadvantage of both these methods is that I'll actually have to figure out the details of how touch input handling works in nickel. Note that once I add either menu (clock or new nav tab button), it will be simple enough to add the other one since I'll be able to re-use the menu widget. I'll also need to look into If I end up going with the idea for a new bottom button, I'll need to design an icon for NM (ideas would be helpful here). Another random thought: I'll be able to reuse most of the menu hook code even with a custom menu. |
The first thing I'm going to look into is showing a custom TouchMenu, as I'll be able to test this on older firmware versions and it'll be easier to debug things later if I figure this out first. The Relevant symbols:
|
Qt resources from 15015 (https://github.com/pgaskin/kobo-plugin-experiments/issues/8#issuecomment-640149720): qss/StatusBarMenu.qssTouchMenu {
padding: 10px;
border: 3px solid black;
background-color: white;
}
TouchMenu::separator {
height: 1px;
background-color: #666666;
margin-top: 5px;
margin-bottom: 5px;
}
TouchMenu {
border: none;
}
NickelTouchMenu {
background-color: transparent;
margin: 14px;
}
MenuTextItem,
MenuImageItem {
background-color: white;
}
MenuTextItem[qApp_deviceIsTrilogy=true],
MenuImageItem[qApp_deviceIsTrilogy=true] {
min-width: 200px;
}
MenuTextItem[qApp_deviceIsPhoenix=true],
MenuImageItem[qApp_deviceIsPhoenix=true] {
min-width: 220px;
}
MenuTextItem[qApp_deviceIsDragon=true],
MenuImageItem[qApp_deviceIsDragon=true] {
min-width: 300px;
}
MenuTextItem[qApp_deviceIsDaylight=true],
MenuImageItem[qApp_deviceIsDaylight=true] {
min-width: 390px;
}
MenuTextItem[qApp_deviceIsStorm=true],
MenuImageItem[qApp_deviceIsStorm=true] {
min-width: 350px;
}
MenuTextItem[qApp_deviceIsTrilogy=true] {
min-height: 46px;
max-height: 46px;
}
MenuTextItem[qApp_deviceIsPhoenix=true] {
min-height: 56px;
max-height: 56px;
}
MenuTextItem[qApp_deviceIsDragon=true] {
min-height: 70px;
max-height: 70px;
}
MenuTextItem[qApp_deviceIsDaylight=true] {
min-height: 90px;
max-height: 90px;
}
MenuTextItem[qApp_deviceIsStorm=true] {
min-height: 80px;
max-height: 80px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsTrilogy=true] {
min-height: 57px;
max-height: 57px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsPhoenix=true] {
min-height: 70px;
max-height: 70px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsDragon=true] {
min-height: 87px;
max-height: 87px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsDaylight=true] {
min-height: 112px;
max-height: 112px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsStorm=true] {
min-height: 98px;
max-height: 98px;
}
MenuTextItem #menuTextItemLabel[italics=true] {
font-family: Georgia;
font-style: italic;
}
MenuTextItem #menuTextItemLabel {
qproperty-leading: 0;
background-color: white;
color: black;
}
MenuTextItem #menuTextItemLabel[localeName=\"ja\"] {
font-family: Sans-SerifJP, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[localeName=\"zh\"] {
font-family: Sans-SerifZH-Simplified, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[localeName=\"zh-HK\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[localeName=\"zh-TW\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsTrilogy=true] {
font-size: 19px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsPhoenix=true] {
font-size: 23px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDragon=true] {
font-size: 29px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsAlyssum=true] {
font-size: 32px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsNova=true] {
font-size: 32px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsStorm=true] {
font-size: 34px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDaylight=true] {
font-size: 37px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsTrilogy=true] {
padding-top: 2px;
padding-bottom: 2px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsPhoenix=true] {
padding-top: 3px;
padding-bottom: 3px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDragon=true] {
padding-top: 4px;
padding-bottom: 4px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDaylight=true] {
padding-top: 5px;
padding-bottom: 5px;
}
MenuTextItem #menuTextItemLabel:disabled {
color: #999999;
}
#sectionLabel[localeName=\"ja\"],
#sectionTitle[localeName=\"ja\"] {
font-family: Sans-SerifJP, sans-serif;
font-style: normal;
}
#sectionLabel[localeName=\"zh\"],
#sectionTitle[localeName=\"zh\"] {
font-family: Sans-SerifZH-Simplified, sans-serif;
font-style: normal;
}
#sectionLabel[localeName=\"zh-HK\"],
#sectionTitle[localeName=\"zh-HK\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
#sectionLabel[localeName=\"zh-TW\"],
#sectionTitle[localeName=\"zh-TW\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
#sectionLabel[qApp_deviceIsTrilogy=true],
#sectionTitle[qApp_deviceIsTrilogy=true] {
min-height: 46px;
max-height: 46px;
}
#sectionLabel[qApp_deviceIsPhoenix=true],
#sectionTitle[qApp_deviceIsPhoenix=true] {
min-height: 56px;
max-height: 56px;
}
#sectionLabel[qApp_deviceIsDragon=true],
#sectionTitle[qApp_deviceIsDragon=true] {
min-height: 70px;
max-height: 70px;
}
#sectionLabel[qApp_deviceIsDaylight=true],
#sectionTitle[qApp_deviceIsDaylight=true] {
min-height: 90px;
max-height: 90px;
}
#sectionLabel[qApp_deviceIsStorm=true],
#sectionTitle[qApp_deviceIsStorm=true] {
min-height: 80px;
max-height: 80px;
}
#sectionLabel[qApp_deviceIsTrilogy=true],
#sectionTitle[qApp_deviceIsTrilogy=true] {
padding-left: 12px;
}
#sectionLabel[qApp_deviceIsPhoenix=true],
#sectionTitle[qApp_deviceIsPhoenix=true] {
padding-left: 16px;
}
#sectionLabel[qApp_deviceIsDragon=true],
#sectionTitle[qApp_deviceIsDragon=true] {
padding-left: 22px;
}
#sectionLabel[qApp_deviceIsDaylight=true],
#sectionTitle[qApp_deviceIsDaylight=true] {
padding-left: 28px;
}
#sectionLabel[qApp_deviceIsStorm=true],
#sectionTitle[qApp_deviceIsStorm=true] {
padding-left: 25px;
}
#sectionLabel[qApp_deviceIsTrilogy=true],
#sectionTitle[qApp_deviceIsTrilogy=true] {
font-size: 17px;
}
#sectionLabel[qApp_deviceIsPhoenix=true],
#sectionTitle[qApp_deviceIsPhoenix=true] {
font-size: 22px;
}
#sectionLabel[qApp_deviceIsDragon=true],
#sectionTitle[qApp_deviceIsDragon=true] {
font-size: 26px;
}
#sectionLabel[qApp_deviceIsAlyssum=true],
#sectionTitle[qApp_deviceIsAlyssum=true] {
font-size: 30px;
}
#sectionLabel[qApp_deviceIsNova=true],
#sectionTitle[qApp_deviceIsNova=true] {
font-size: 30px;
}
#sectionLabel[qApp_deviceIsStorm=true],
#sectionTitle[qApp_deviceIsStorm=true] {
font-size: 30px;
}
#sectionLabel[qApp_deviceIsDaylight=true],
#sectionTitle[qApp_deviceIsDaylight=true] {
font-size: 34px;
}
#acceptButton {
qproperty-primaryButton: true;
}
#rejectButton {
qproperty-primaryButton: false;
}
StatusBarMenu[qApp_deviceIsTrilogy=true] {
margin: 15px;
}
StatusBarMenu[qApp_deviceIsPhoenix=true] {
margin: 20px;
}
StatusBarMenu[qApp_deviceIsDragon=true] {
margin: 30px;
}
StatusBarMenu[qApp_deviceIsDaylight=true] {
margin: 39px;
}
StatusBarMenu[qApp_deviceIsStorm=true] {
margin: 35px;
}
MenuTextItem #leftSpacer[qApp_deviceIsTrilogy=true],
MenuTextItem #rightSpacer[qApp_deviceIsTrilogy=true] {
max-width: 12px;
min-width: 12px;
}
MenuTextItem #leftSpacer[qApp_deviceIsPhoenix=true],
MenuTextItem #rightSpacer[qApp_deviceIsPhoenix=true] {
max-width: 15px;
min-width: 15px;
}
MenuTextItem #leftSpacer[qApp_deviceIsDragon=true],
MenuTextItem #rightSpacer[qApp_deviceIsDragon=true] {
max-width: 20px;
min-width: 20px;
}
MenuTextItem #leftSpacer[qApp_deviceIsDaylight=true],
MenuTextItem #rightSpacer[qApp_deviceIsDaylight=true] {
max-width: 26px;
min-width: 26px;
}
MenuTextItem #leftSpacer[qApp_deviceIsStorm=true],
MenuTextItem #rightSpacer[qApp_deviceIsStorm=true] {
max-width: 23px;
min-width: 23px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsTrilogy=true] {
font-size: 19px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsPhoenix=true] {
font-size: 23px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDragon=true] {
font-size: 32px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsStorm=true] {
font-size: 37px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDaylight=true] {
font-size: 42px;
} qss/NickelTouchMenu.qssTouchMenu {
border: none;
}
NickelTouchMenu {
background-color: transparent;
margin: 14px;
}
MenuTextItem,
MenuImageItem {
background-color: white;
}
MenuTextItem[qApp_deviceIsTrilogy=true],
MenuImageItem[qApp_deviceIsTrilogy=true] {
min-width: 200px;
}
MenuTextItem[qApp_deviceIsPhoenix=true],
MenuImageItem[qApp_deviceIsPhoenix=true] {
min-width: 220px;
}
MenuTextItem[qApp_deviceIsDragon=true],
MenuImageItem[qApp_deviceIsDragon=true] {
min-width: 300px;
}
MenuTextItem[qApp_deviceIsDaylight=true],
MenuImageItem[qApp_deviceIsDaylight=true] {
min-width: 390px;
}
MenuTextItem[qApp_deviceIsStorm=true],
MenuImageItem[qApp_deviceIsStorm=true] {
min-width: 350px;
}
MenuTextItem[qApp_deviceIsTrilogy=true] {
min-height: 46px;
max-height: 46px;
}
MenuTextItem[qApp_deviceIsPhoenix=true] {
min-height: 56px;
max-height: 56px;
}
MenuTextItem[qApp_deviceIsDragon=true] {
min-height: 70px;
max-height: 70px;
}
MenuTextItem[qApp_deviceIsDaylight=true] {
min-height: 90px;
max-height: 90px;
}
MenuTextItem[qApp_deviceIsStorm=true] {
min-height: 80px;
max-height: 80px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsTrilogy=true] {
min-height: 57px;
max-height: 57px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsPhoenix=true] {
min-height: 70px;
max-height: 70px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsDragon=true] {
min-height: 87px;
max-height: 87px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsDaylight=true] {
min-height: 112px;
max-height: 112px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsStorm=true] {
min-height: 98px;
max-height: 98px;
}
MenuTextItem #menuTextItemLabel[italics=true] {
font-family: Georgia;
font-style: italic;
}
MenuTextItem #menuTextItemLabel {
qproperty-leading: 0;
background-color: white;
color: black;
}
MenuTextItem #menuTextItemLabel[localeName=\"ja\"] {
font-family: Sans-SerifJP, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[localeName=\"zh\"] {
font-family: Sans-SerifZH-Simplified, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[localeName=\"zh-HK\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[localeName=\"zh-TW\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsTrilogy=true] {
font-size: 19px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsPhoenix=true] {
font-size: 23px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDragon=true] {
font-size: 29px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsAlyssum=true] {
font-size: 32px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsNova=true] {
font-size: 32px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsStorm=true] {
font-size: 34px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDaylight=true] {
font-size: 37px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsTrilogy=true] {
padding-top: 2px;
padding-bottom: 2px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsPhoenix=true] {
padding-top: 3px;
padding-bottom: 3px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDragon=true] {
padding-top: 4px;
padding-bottom: 4px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDaylight=true] {
padding-top: 5px;
padding-bottom: 5px;
}
MenuTextItem #menuTextItemLabel:disabled {
color: #999999;
}
#sectionLabel[localeName=\"ja\"],
#sectionTitle[localeName=\"ja\"] {
font-family: Sans-SerifJP, sans-serif;
font-style: normal;
}
#sectionLabel[localeName=\"zh\"],
#sectionTitle[localeName=\"zh\"] {
font-family: Sans-SerifZH-Simplified, sans-serif;
font-style: normal;
}
#sectionLabel[localeName=\"zh-HK\"],
#sectionTitle[localeName=\"zh-HK\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
#sectionLabel[localeName=\"zh-TW\"],
#sectionTitle[localeName=\"zh-TW\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
#sectionLabel[qApp_deviceIsTrilogy=true],
#sectionTitle[qApp_deviceIsTrilogy=true] {
min-height: 46px;
max-height: 46px;
}
#sectionLabel[qApp_deviceIsPhoenix=true],
#sectionTitle[qApp_deviceIsPhoenix=true] {
min-height: 56px;
max-height: 56px;
}
#sectionLabel[qApp_deviceIsDragon=true],
#sectionTitle[qApp_deviceIsDragon=true] {
min-height: 70px;
max-height: 70px;
}
#sectionLabel[qApp_deviceIsDaylight=true],
#sectionTitle[qApp_deviceIsDaylight=true] {
min-height: 90px;
max-height: 90px;
}
#sectionLabel[qApp_deviceIsStorm=true],
#sectionTitle[qApp_deviceIsStorm=true] {
min-height: 80px;
max-height: 80px;
}
#sectionLabel[qApp_deviceIsTrilogy=true],
#sectionTitle[qApp_deviceIsTrilogy=true] {
padding-left: 12px;
}
#sectionLabel[qApp_deviceIsPhoenix=true],
#sectionTitle[qApp_deviceIsPhoenix=true] {
padding-left: 16px;
}
#sectionLabel[qApp_deviceIsDragon=true],
#sectionTitle[qApp_deviceIsDragon=true] {
padding-left: 22px;
}
#sectionLabel[qApp_deviceIsDaylight=true],
#sectionTitle[qApp_deviceIsDaylight=true] {
padding-left: 28px;
}
#sectionLabel[qApp_deviceIsStorm=true],
#sectionTitle[qApp_deviceIsStorm=true] {
padding-left: 25px;
}
#sectionLabel[qApp_deviceIsTrilogy=true],
#sectionTitle[qApp_deviceIsTrilogy=true] {
font-size: 17px;
}
#sectionLabel[qApp_deviceIsPhoenix=true],
#sectionTitle[qApp_deviceIsPhoenix=true] {
font-size: 22px;
}
#sectionLabel[qApp_deviceIsDragon=true],
#sectionTitle[qApp_deviceIsDragon=true] {
font-size: 26px;
}
#sectionLabel[qApp_deviceIsAlyssum=true],
#sectionTitle[qApp_deviceIsAlyssum=true] {
font-size: 30px;
}
#sectionLabel[qApp_deviceIsNova=true],
#sectionTitle[qApp_deviceIsNova=true] {
font-size: 30px;
}
#sectionLabel[qApp_deviceIsStorm=true],
#sectionTitle[qApp_deviceIsStorm=true] {
font-size: 30px;
}
#sectionLabel[qApp_deviceIsDaylight=true],
#sectionTitle[qApp_deviceIsDaylight=true] {
font-size: 34px;
}
#acceptButton {
qproperty-primaryButton: true;
}
#rejectButton {
qproperty-primaryButton: false;
} qss/TouchMenu.qssTouchMenu {
padding: 10px;
border: 3px solid black;
background-color: white;
}
TouchMenu::separator {
height: 1px;
background-color: #666666;
margin-top: 5px;
margin-bottom: 5px;
} qss/GoToPageMenuView.qssTouchMenu {
padding: 10px;
border: 3px solid black;
background-color: white;
}
TouchMenu::separator {
height: 1px;
background-color: #666666;
margin-top: 5px;
margin-bottom: 5px;
}
TouchMenu {
border: none;
}
NickelTouchMenu {
background-color: transparent;
margin: 14px;
}
MenuTextItem,
MenuImageItem {
background-color: white;
}
MenuTextItem[qApp_deviceIsTrilogy=true],
MenuImageItem[qApp_deviceIsTrilogy=true] {
min-width: 200px;
}
MenuTextItem[qApp_deviceIsPhoenix=true],
MenuImageItem[qApp_deviceIsPhoenix=true] {
min-width: 220px;
}
MenuTextItem[qApp_deviceIsDragon=true],
MenuImageItem[qApp_deviceIsDragon=true] {
min-width: 300px;
}
MenuTextItem[qApp_deviceIsDaylight=true],
MenuImageItem[qApp_deviceIsDaylight=true] {
min-width: 390px;
}
MenuTextItem[qApp_deviceIsStorm=true],
MenuImageItem[qApp_deviceIsStorm=true] {
min-width: 350px;
}
MenuTextItem[qApp_deviceIsTrilogy=true] {
min-height: 46px;
max-height: 46px;
}
MenuTextItem[qApp_deviceIsPhoenix=true] {
min-height: 56px;
max-height: 56px;
}
MenuTextItem[qApp_deviceIsDragon=true] {
min-height: 70px;
max-height: 70px;
}
MenuTextItem[qApp_deviceIsDaylight=true] {
min-height: 90px;
max-height: 90px;
}
MenuTextItem[qApp_deviceIsStorm=true] {
min-height: 80px;
max-height: 80px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsTrilogy=true] {
min-height: 57px;
max-height: 57px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsPhoenix=true] {
min-height: 70px;
max-height: 70px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsDragon=true] {
min-height: 87px;
max-height: 87px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsDaylight=true] {
min-height: 112px;
max-height: 112px;
}
MenuTextItem[qApp_isFontScaleLarge=true][qApp_deviceIsStorm=true] {
min-height: 98px;
max-height: 98px;
}
MenuTextItem #menuTextItemLabel[italics=true] {
font-family: Georgia;
font-style: italic;
}
MenuTextItem #menuTextItemLabel {
qproperty-leading: 0;
background-color: white;
color: black;
}
MenuTextItem #menuTextItemLabel[localeName=\"ja\"] {
font-family: Sans-SerifJP, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[localeName=\"zh\"] {
font-family: Sans-SerifZH-Simplified, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[localeName=\"zh-HK\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[localeName=\"zh-TW\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsTrilogy=true] {
font-size: 19px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsPhoenix=true] {
font-size: 23px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDragon=true] {
font-size: 29px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsAlyssum=true] {
font-size: 32px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsNova=true] {
font-size: 32px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsStorm=true] {
font-size: 34px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDaylight=true] {
font-size: 37px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsTrilogy=true] {
padding-top: 2px;
padding-bottom: 2px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsPhoenix=true] {
padding-top: 3px;
padding-bottom: 3px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDragon=true] {
padding-top: 4px;
padding-bottom: 4px;
}
MenuTextItem #menuTextItemLabel[qApp_deviceIsDaylight=true] {
padding-top: 5px;
padding-bottom: 5px;
}
MenuTextItem #menuTextItemLabel:disabled {
color: #999999;
}
#sectionLabel[localeName=\"ja\"],
#sectionTitle[localeName=\"ja\"] {
font-family: Sans-SerifJP, sans-serif;
font-style: normal;
}
#sectionLabel[localeName=\"zh\"],
#sectionTitle[localeName=\"zh\"] {
font-family: Sans-SerifZH-Simplified, sans-serif;
font-style: normal;
}
#sectionLabel[localeName=\"zh-HK\"],
#sectionTitle[localeName=\"zh-HK\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
#sectionLabel[localeName=\"zh-TW\"],
#sectionTitle[localeName=\"zh-TW\"] {
font-family: Sans-SerifZH-Traditional, sans-serif;
font-style: normal;
}
#sectionLabel[qApp_deviceIsTrilogy=true],
#sectionTitle[qApp_deviceIsTrilogy=true] {
min-height: 46px;
max-height: 46px;
}
#sectionLabel[qApp_deviceIsPhoenix=true],
#sectionTitle[qApp_deviceIsPhoenix=true] {
min-height: 56px;
max-height: 56px;
}
#sectionLabel[qApp_deviceIsDragon=true],
#sectionTitle[qApp_deviceIsDragon=true] {
min-height: 70px;
max-height: 70px;
}
#sectionLabel[qApp_deviceIsDaylight=true],
#sectionTitle[qApp_deviceIsDaylight=true] {
min-height: 90px;
max-height: 90px;
}
#sectionLabel[qApp_deviceIsStorm=true],
#sectionTitle[qApp_deviceIsStorm=true] {
min-height: 80px;
max-height: 80px;
}
#sectionLabel[qApp_deviceIsTrilogy=true],
#sectionTitle[qApp_deviceIsTrilogy=true] {
padding-left: 12px;
}
#sectionLabel[qApp_deviceIsPhoenix=true],
#sectionTitle[qApp_deviceIsPhoenix=true] {
padding-left: 16px;
}
#sectionLabel[qApp_deviceIsDragon=true],
#sectionTitle[qApp_deviceIsDragon=true] {
padding-left: 22px;
}
#sectionLabel[qApp_deviceIsDaylight=true],
#sectionTitle[qApp_deviceIsDaylight=true] {
padding-left: 28px;
}
#sectionLabel[qApp_deviceIsStorm=true],
#sectionTitle[qApp_deviceIsStorm=true] {
padding-left: 25px;
}
#sectionLabel[qApp_deviceIsTrilogy=true],
#sectionTitle[qApp_deviceIsTrilogy=true] {
font-size: 17px;
}
#sectionLabel[qApp_deviceIsPhoenix=true],
#sectionTitle[qApp_deviceIsPhoenix=true] {
font-size: 22px;
}
#sectionLabel[qApp_deviceIsDragon=true],
#sectionTitle[qApp_deviceIsDragon=true] {
font-size: 26px;
}
#sectionLabel[qApp_deviceIsAlyssum=true],
#sectionTitle[qApp_deviceIsAlyssum=true] {
font-size: 30px;
}
#sectionLabel[qApp_deviceIsNova=true],
#sectionTitle[qApp_deviceIsNova=true] {
font-size: 30px;
}
#sectionLabel[qApp_deviceIsStorm=true],
#sectionTitle[qApp_deviceIsStorm=true] {
font-size: 30px;
}
#sectionLabel[qApp_deviceIsDaylight=true],
#sectionTitle[qApp_deviceIsDaylight=true] {
font-size: 34px;
}
#acceptButton {
qproperty-primaryButton: true;
}
#rejectButton {
qproperty-primaryButton: false;
}
#label {
padding-left: 0px;
}
#label[qApp_deviceIsTrilogy=true] {
font-size: 17px;
}
#label[qApp_deviceIsPhoenix=true] {
font-size: 22px;
}
#label[qApp_deviceIsDragon=true] {
font-size: 26px;
}
#label[qApp_deviceIsAlyssum=true] {
font-size: 30px;
}
#label[qApp_deviceIsNova=true] {
font-size: 30px;
}
#label[qApp_deviceIsStorm=true] {
font-size: 30px;
}
#label[qApp_deviceIsDaylight=true] {
font-size: 34px;
}
#lineEdit {
qproperty-clearButtonAllowed: false;
}
#lineEdit[qApp_deviceIsTrilogy=true] {
max-width: 95px;
min-width: 95px;
}
#lineEdit[qApp_deviceIsPhoenix=true] {
max-width: 115px;
min-width: 115px;
}
#lineEdit[qApp_deviceIsDragon=true] {
max-width: 145px;
min-width: 145px;
}
#lineEdit[qApp_deviceIsDaylight=true] {
max-width: 185px;
min-width: 185px;
}
#lineEdit[qApp_deviceIsStorm=true] {
max-width: 170px;
min-width: 170px;
}
#totalPages {
padding-right: 0px;
}
#totalPages[localeName=\"ja\"] {
qproperty-leading: 5;
qproperty-textFormat: RichText;
}
#totalPages[localeName=\"zh\"] {
qproperty-leading: 5;
qproperty-textFormat: RichText;
}
#totalPages[localeName=\"zh-HK\"] {
qproperty-leading: 5;
qproperty-textFormat: RichText;
}
#totalPages[localeName=\"zh-TW\"] {
qproperty-leading: 5;
qproperty-textFormat: RichText;
} Note that The main differences between the styles for
|
Note to self:
|
The The simplest thing to do right now would be to intercept the "More" tab and make it show the custom menu with another "More" button inside it to show the real tab. This adds an additional tap to get to those items, but most of those items can be added to NickelMenu directly anyways (and I can add the ones which can't be right now). I'm currently looking into how feasible it would be to add a new tab button entirely. Regarding the custom TouchMenu itself, I'm nearly finished. I just need to figure out the simplest and most future-proof way to handle the triggered signal for the action (see 19329da). |
I've figured out a somewhat hacky way to handle the touch events on the menu item without needing a // `it` is the MenuTextItem
// `ac` is the QWidgetAction with `it` as the widget
if (!QWidget::connect(reinterpret_cast<QWidget*>(it), SIGNAL(tapped(bool)), ac, SIGNAL(triggered()))) {
reinterpret_cast<QMenu*>(menu)->deleteLater();
NM_ERR_RET(nullptr, "could not handle touch events for menu item (connection of SIGNAL(tapped(bool)) on MenuTextItem to SIGNAL(triggered()) on QWidgetAction failed)");
} See 3660bed. Now, I just need to polish that code a bit, figure out positioning, and figure out where I'm going to actually put the trigger for the menu to show. |
I have managed to make an ugly and misaligned, but working trigger where the clock is, but I don't think I'll be going with that approach, at least for the next release, as it's a bit buggy and complex. I'll probably end up going with my idea of intercepting the "More" button and showing NickelMenu along with another button to show the actual "More" menu for now. |
I ended up going with the idea to add another item to the bottom tab bar, as it ended up being relatively straightforward and it wasn't too messy. Here's what it looks like right now:
@shermp, @NiLuJe, @jackiew1, do you think I should make a custom icon for it (if so, I'd appreciate ideas, as I'm not really good with icon design)? |
It's entirely up to you but with my predictable always-look-on-the-dark-side approach, personally I wouldn't do a special icon for these reasons:
It's got can-of-worms written all over it as far as I can see. But when did that ever deter your more positive outlook. 😃 ETA: Forgot to add that the extra menu in the footer looks fine to me. |
Remember that we're running as part of Nickel, so we can just embed our own icon in NM (the Qt resources are registered globally).
I think these ones are scaled, but I'll check to make sure. Update: They are pre-scaled and included in nested resource roots which are separate for each device: https://github.com/pgaskin/kobo-plugin-experiments/issues/8#issuecomment-672587633.
This one is slightly different, as it's drawn manually by the
This one isn't as bad as it seems since we have access to the proper Qt stuff rather than patching the binary directly. The real can-of-worms I was concerned about was my original idea to replace the clock with a menu button, as the code I had for that was quite messy and I didn't feel completely comfortable with its stability or how well it would work on different screen sizes.
Yes. I'm also starting to get used to that position myself. It helps that it's right against the edge of the screen because that makes it quite easy to press blindly the way I used to with the top-left menu. And, it does make the bottom nav look a lot more balanced. |
I wouldn't mind a custom icon, yeah, and I kinda agree about what was
proposed (i.e., something along those lines:
https://github.com/koreader/koreader/blob/master/resources/icons/appbar.tools.png
).
…On Tue, Aug 11, 2020, 18:40 Patrick Gaskin ***@***.***> wrote:
If you open Pandora's Box for customising the NM icon don't be surprised
if you get requests to allow icon customisation in other parts of the GUI.
Remember that we're running as part of Nickel, so we can just embed our
own icon in NM (the Qt resources are registered globally).
Don't you have to provide a different size icon for each of the different
Kobo models?
I think these ones are scaled, but I'll check to make sure.
As far as I remember nickel's CSS streams are coded to expect fixed icon
sizes by model.
This one is slightly different, as it's drawn manually by the
MainNavButton.
It's got can-of-worms written all over it as far as I can see
This one isn't as bad as it seems since we have access to the proper Qt
stuff rather than patching the binary directly. The real can-of-worms I was
concerned about was my original idea to replace the clock with a menu
button, as the code I had for that was quite messy and I didn't feel
completely comfortable with its stability or how well it would work on
different screen sizes.
ETA: Forgot to add that the extra menu in the footer looks fine to me.
Yes. I'm also starting to get used to that position myself. It helps that
it's right against the edge of the screen because that makes it quite easy
to press blindly the way I used to with the top-left menu. And, it does
make the bottom nav look a lot more balanced.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#78 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAA3KZRNTKBNGCHZDNSIIRLSAFX6FANCNFSM4P2IWAHA>
.
|
@pgaskin, could you swap between nickelmenu tab and more tab? the home screen will look more intuitive. when we mean more, it should be the last menu we looking for |
MR:post-4021495
MR:thread-332254
The text was updated successfully, but these errors were encountered: