View Single Post
Old 06-12-2025, 04:07 PM   #32
BeckyEbook
Guru
BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.
 
BeckyEbook's Avatar
 
Posts: 863
Karma: 3461504
Join Date: Jan 2017
Location: Poland
Device: Various
I built Sigil and it looks encouraging.

Still missing is the disabling of the "Role" menu for the EPUB2 file, if you're considering it, because there's no precedent.
In my private version I use this way to disable the Tools > Epub3 Tools menu when I edit an EPUB2 file.

The easiest way to do this is by adding a paremeter for SetStateActionsCodeView:

Call:
Code:
QString epubversion = m_Book->GetConstOPF()->GetEpubVersion();
SetStateActionsCodeView(epubversion);
Function:
Code:
void MainWindow::SetStateActionsCodeView(QString epubversion)
{
    ...
    ui.actionInsertRole->setEnabled(epubversion == "2.0" ? false : true);
    ...
    ui.menuEPUB3Tools->setEnabled(epubversion == "2.0" ? false : true);
    ...
This idea only comes from the fact that [quote]:
"As XHTML 1.0 was released before ARIA 1.0, EPUB 2 does not support the use of ARIA attributes. Inclusion of the attributes will result in validation errors."
BeckyEbook is offline   Reply With Quote