Merge pull request #1331 from xiaoyifang/opt/scanpopup

opt: use link instead of button and tooltip
This commit is contained in:
xiaoyifang 2023-12-20 15:27:54 +08:00 committed by GitHub
commit a7eff055c8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 2 additions and 69 deletions

View file

@ -250,11 +250,6 @@ std::string ArticleMaker::makeNotFoundBody( QString const & word, QString const
string ArticleMaker::makeWelcomeHtml() const
{
string result = makeHtmlHeader( tr( "Welcome!" ), QString(), cfg.alwaysExpandOptionalParts );
//tooltip
result += R"(<script src="qrc:///scripts/popper.min.js"></script>)";
result += R"(<script src="qrc:///scripts/tippy.min.js"></script>)";
result += R"(<link href="qrc:///tippy-light.css" rel="stylesheet">)";
result +=
tr(
@ -262,7 +257,7 @@ string ArticleMaker::makeWelcomeHtml() const
"<p>To start working with the program, first visit <b>Edit|Dictionaries</b> to add some directory paths where to search "
"for the dictionary files, set up various Wikipedia sites or other sources, adjust dictionary order or create dictionary groups."
"<p>And then you're ready to look up your words! You can do that in this window "
"by using a pane to the left, or you can <button id=\"lookup-popup\">look up words from other active applications</button>. "
"by using a pane to the left, or you can <a href=\"https://xiaoyifang.github.io/goldendict-ng/ui_popup/\">look up words from other active applications</a>. "
"<p>To customize program, check out the available preferences at <b>Edit|Preferences</b>. "
"All settings there have tooltips, be sure to read them if you are in doubt about anything."
"<p>Should you need further help, have any questions, "
@ -302,19 +297,6 @@ string ArticleMaker::makeWelcomeHtml() const
theme = "light";
}
result += QString(
R"(<script>
const template = document.getElementById('popup');
tippy('#lookup-popup', {
content: template.innerHTML,
allowHTML: true,
theme: '%1'
});
</script>)" )
.arg( theme )
.toStdString();
result += "</body></html>";
return result;

File diff suppressed because one or more lines are too long

View file

@ -7,8 +7,6 @@
<file>iframeResizer.contentWindow.min.js</file>
<file>iframeResizer.min.js</file>
<file>jquery-3.6.0.slim.min.js</file>
<file>popper.min.js</file>
<file>tippy.min.js</file>
<file>mark.min.js</file>
</qresource>
</RCC>

File diff suppressed because one or more lines are too long

View file

@ -17,6 +17,5 @@
<file>qt-style-win.css</file>
<file>qt-style.css</file>
<file>article-style-darkmode.css</file>
<file>tippy-light.css</file>
</qresource>
</RCC>

View file

@ -1,27 +0,0 @@
.tippy-box[data-theme~="light"] {
color: #26323d;
box-shadow:
0 0 20px 4px rgba(154, 161, 177, 0.15),
0 4px 80px -8px rgba(36, 40, 47, 0.25),
0 4px 4px -2px rgba(91, 94, 105, 0.15);
background-color: #fff;
}
.tippy-box[data-theme~="light"][data-placement^="top"] > .tippy-arrow:before {
border-top-color: #fff;
}
.tippy-box[data-theme~="light"][data-placement^="bottom"]
> .tippy-arrow:before {
border-bottom-color: #fff;
}
.tippy-box[data-theme~="light"][data-placement^="left"] > .tippy-arrow:before {
border-left-color: #fff;
}
.tippy-box[data-theme~="light"][data-placement^="right"] > .tippy-arrow:before {
border-right-color: #fff;
}
.tippy-box[data-theme~="light"] > .tippy-backdrop {
background-color: #fff;
}
.tippy-box[data-theme~="light"] > .tippy-svg-arrow {
fill: #fff;
}

View file

@ -1,4 +1,4 @@
# Use vcpkg to build ffmpeg.
# Use vcpkg to build ffmpeg(on Windows).
Steps:
@ -23,17 +23,6 @@ Then replace the dlls and libs in the winlibs\lib\msvc.
**Pros**: Easy to manage.
# I have tried the following methods without success
## Use the scripts provided by the following url
https://github.com/Microsoft/FFmpegInterop/issues/67
https://github.com/Microsoft/FFmpegInterop
did not know how to link to libspeex.
## conan
conan does not seem to have the libspeex option yet.