qt_demoe/docs/bigscreen/index.html

756 lines
419 KiB
HTML
Raw Normal View History

2022-06-02 06:34:10 +00:00
<!doctype html>
2021-07-10 09:34:53 +00:00
<html>
<head>
2022-06-02 06:34:10 +00:00
<meta charset='UTF-8'><meta name='viewport' content='width=device-width initial-scale=1'>
2023-12-25 05:50:42 +00:00
<link href='https://fonts.googleapis.com/css?family=Open+Sans:400italic,700italic,700,400&subset=latin,latin-ext' rel='stylesheet' type='text/css' /><style type='text/css'>html {overflow-x: initial !important;}:root { --bg-color:#ffffff; --text-color:#333333; --select-text-bg-color:#B5D6FC; --select-text-font-color:auto; --monospace:"Lucida Console",Consolas,"Courier",monospace; --title-bar-height:20px; }
2022-06-02 06:34:10 +00:00
.mac-os-11 { --title-bar-height:28px; }
html { font-size: 14px; background-color: var(--bg-color); color: var(--text-color); font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; -webkit-font-smoothing: antialiased; }
2023-12-25 05:50:42 +00:00
h1, h2, h3, h4, h5 { white-space: pre-wrap; }
body { margin: 0px; padding: 0px; height: auto; inset: 0px; font-size: 1rem; line-height: 1.42857; overflow-x: hidden; background: inherit; }
2022-06-02 06:34:10 +00:00
iframe { margin: auto; }
a.url { word-break: break-all; }
a:active, a:hover { outline: 0px; }
.in-text-selection, ::selection { text-shadow: none; background: var(--select-text-bg-color); color: var(--select-text-font-color); }
#write { margin: 0px auto; height: auto; width: inherit; word-break: normal; overflow-wrap: break-word; position: relative; white-space: normal; overflow-x: visible; padding-top: 36px; }
#write.first-line-indent p { text-indent: 2em; }
#write.first-line-indent li p, #write.first-line-indent p * { text-indent: 0px; }
#write.first-line-indent li { margin-left: 2em; }
.for-image #write { padding-left: 8px; padding-right: 8px; }
body.typora-export { padding-left: 30px; padding-right: 30px; }
.typora-export .footnote-line, .typora-export li, .typora-export p { white-space: pre-wrap; }
.typora-export .task-list-item input { pointer-events: none; }
@media screen and (max-width: 500px) {
body.typora-export { padding-left: 0px; padding-right: 0px; }
#write { padding-left: 20px; padding-right: 20px; }
}
#write li > figure:last-child { margin-bottom: 0.5rem; }
#write ol, #write ul { position: relative; }
img { max-width: 100%; vertical-align: middle; image-orientation: from-image; }
button, input, select, textarea { color: inherit; font: inherit; }
input[type="checkbox"], input[type="radio"] { line-height: normal; padding: 0px; }
*, ::after, ::before { box-sizing: border-box; }
#write h1, #write h2, #write h3, #write h4, #write h5, #write h6, #write p, #write pre { width: inherit; }
#write h1, #write h2, #write h3, #write h4, #write h5, #write h6, #write p { position: relative; }
p { line-height: inherit; }
h1, h2, h3, h4, h5, h6 { break-after: avoid-page; break-inside: avoid; orphans: 4; }
p { orphans: 4; }
h1 { font-size: 2rem; }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.6rem; }
h4 { font-size: 1.4rem; }
h5 { font-size: 1.2rem; }
h6 { font-size: 1rem; }
.md-math-block, .md-rawblock, h1, h2, h3, h4, h5, h6, p { margin-top: 1rem; margin-bottom: 1rem; }
.hidden { display: none; }
.md-blockmeta { color: rgb(204, 204, 204); font-weight: 700; font-style: italic; }
a { cursor: pointer; }
sup.md-footnote { padding: 2px 4px; background-color: rgba(238, 238, 238, 0.7); color: rgb(85, 85, 85); border-radius: 4px; cursor: pointer; }
sup.md-footnote a, sup.md-footnote a:hover { color: inherit; text-transform: inherit; text-decoration: inherit; }
#write input[type="checkbox"] { cursor: pointer; width: inherit; height: inherit; }
figure { overflow-x: auto; margin: 1.2em 0px; max-width: calc(100% + 16px); padding: 0px; }
figure > table { margin: 0px; }
2022-07-04 06:50:37 +00:00
thead, tr { break-inside: avoid; break-after: auto; }
2022-06-02 06:34:10 +00:00
thead { display: table-header-group; }
table { border-collapse: collapse; border-spacing: 0px; width: 100%; overflow: auto; break-inside: auto; text-align: left; }
table.md-table td { min-width: 32px; }
.CodeMirror-gutters { border-right: 0px; background-color: inherit; }
.CodeMirror-linenumber { user-select: none; }
.CodeMirror { text-align: left; }
.CodeMirror-placeholder { opacity: 0.3; }
.CodeMirror pre { padding: 0px 4px; }
.CodeMirror-lines { padding: 0px; }
div.hr:focus { cursor: none; }
#write pre { white-space: pre-wrap; }
#write.fences-no-line-wrapping pre { white-space: pre; }
#write pre.ty-contain-cm { white-space: normal; }
.CodeMirror-gutters { margin-right: 4px; }
.md-fences { font-size: 0.9rem; display: block; break-inside: avoid; text-align: left; overflow: visible; white-space: pre; background: inherit; position: relative !important; }
.md-fences-adv-panel { width: 100%; margin-top: 10px; text-align: center; padding-top: 0px; padding-bottom: 8px; overflow-x: auto; }
#write .md-fences.mock-cm { white-space: pre-wrap; }
.md-fences.md-fences-with-lineno { padding-left: 0px; }
#write.fences-no-line-wrapping .md-fences.mock-cm { white-space: pre; overflow-x: auto; }
.md-fences.mock-cm.md-fences-with-lineno { padding-left: 8px; }
.CodeMirror-line, twitterwidget { break-inside: avoid; }
2022-07-04 06:50:37 +00:00
svg { break-inside: avoid; }
2022-06-02 06:34:10 +00:00
.footnotes { opacity: 0.8; font-size: 0.9rem; margin-top: 1em; margin-bottom: 1em; }
.footnotes + .footnotes { margin-top: 0px; }
.md-reset { margin: 0px; padding: 0px; border: 0px; outline: 0px; vertical-align: top; background: 0px 0px; text-decoration: none; text-shadow: none; float: none; position: static; width: auto; height: auto; white-space: nowrap; cursor: inherit; -webkit-tap-highlight-color: transparent; line-height: normal; font-weight: 400; text-align: left; box-sizing: content-box; direction: ltr; }
li div { padding-top: 0px; }
blockquote { margin: 1rem 0px; }
li .mathjax-block, li p { margin: 0.5rem 0px; }
li blockquote { margin: 1rem 0px; }
li { margin: 0px; position: relative; }
blockquote > :last-child { margin-bottom: 0px; }
blockquote > :first-child, li > :first-child { margin-top: 0px; }
.footnotes-area { color: rgb(136, 136, 136); margin-top: 0.714rem; padding-bottom: 0.143rem; white-space: normal; }
#write .footnote-line { white-space: pre-wrap; }
@media print {
body, html { border: 1px solid transparent; height: 99%; break-after: avoid; break-before: avoid; font-variant-ligatures: no-common-ligatures; }
2023-12-25 05:50:42 +00:00
#write { margin-top: 0px; border-color: transparent !important; padding-top: 0px !important; padding-bottom: 0px !important; }
2022-06-02 06:34:10 +00:00
.typora-export * { -webkit-print-color-adjust: exact; }
.typora-export #write { break-after: avoid; }
.typora-export #write::after { height: 0px; }
.is-mac table { break-inside: avoid; }
2023-12-25 05:50:42 +00:00
#write > p:nth-child(1) { margin-top: 0px; }
2022-06-02 06:34:10 +00:00
.typora-export-show-outline .typora-export-sidebar { display: none; }
2023-12-25 05:50:42 +00:00
figure { overflow-x: visible; }
2022-06-02 06:34:10 +00:00
}
.footnote-line { margin-top: 0.714em; font-size: 0.7em; }
a img, img a { cursor: pointer; }
pre.md-meta-block { font-size: 0.8rem; min-height: 0.8rem; white-space: pre-wrap; background: rgb(204, 204, 204); display: block; overflow-x: hidden; }
p > .md-image:only-child:not(.md-img-error) img, p > img:only-child { display: block; margin: auto; }
#write.first-line-indent p > .md-image:only-child:not(.md-img-error) img { left: -2em; position: relative; }
p > .md-image:only-child { display: inline-block; width: 100%; }
#write .MathJax_Display { margin: 0.8em 0px 0px; }
.md-math-block { width: 100%; }
.md-math-block:not(:empty)::after { display: none; }
.MathJax_ref { fill: currentcolor; }
[contenteditable="true"]:active, [contenteditable="true"]:focus, [contenteditable="false"]:active, [contenteditable="false"]:focus { outline: 0px; box-shadow: none; }
.md-task-list-item { position: relative; list-style-type: none; }
.task-list-item.md-task-list-item { padding-left: 0px; }
.md-task-list-item > input { position: absolute; top: 0px; left: 0px; margin-left: -1.2em; margin-top: calc(1em - 10px); border: none; }
.math { font-size: 1rem; }
.md-toc { min-height: 3.58rem; position: relative; font-size: 0.9rem; border-radius: 10px; }
.md-toc-content { position: relative; margin-left: 0px; }
.md-toc-content::after, .md-toc::after { display: none; }
.md-toc-item { display: block; color: rgb(65, 131, 196); }
.md-toc-item a { text-decoration: none; }
.md-toc-inner:hover { text-decoration: underline; }
.md-toc-inner { display: inline-block; cursor: pointer; }
.md-toc-h1 .md-toc-inner { margin-left: 0px; font-weight: 700; }
.md-toc-h2 .md-toc-inner { margin-left: 2em; }
.md-toc-h3 .md-toc-inner { margin-left: 4em; }
.md-toc-h4 .md-toc-inner { margin-left: 6em; }
.md-toc-h5 .md-toc-inner { margin-left: 8em; }
.md-toc-h6 .md-toc-inner { margin-left: 10em; }
@media screen and (max-width: 48em) {
.md-toc-h3 .md-toc-inner { margin-left: 3.5em; }
.md-toc-h4 .md-toc-inner { margin-left: 5em; }
.md-toc-h5 .md-toc-inner { margin-left: 6.5em; }
.md-toc-h6 .md-toc-inner { margin-left: 8em; }
}
a.md-toc-inner { font-size: inherit; font-style: inherit; font-weight: inherit; line-height: inherit; }
.footnote-line a:not(.reversefootnote) { color: inherit; }
2022-07-04 06:50:37 +00:00
.reversefootnote { font-family: ui-monospace, sans-serif; }
2022-06-02 06:34:10 +00:00
.md-attr { display: none; }
.md-fn-count::after { content: "."; }
code, pre, samp, tt { font-family: var(--monospace); }
kbd { margin: 0px 0.1em; padding: 0.1em 0.6em; font-size: 0.8em; color: rgb(36, 39, 41); background: rgb(255, 255, 255); border: 1px solid rgb(173, 179, 185); border-radius: 3px; box-shadow: rgba(12, 13, 14, 0.2) 0px 1px 0px, rgb(255, 255, 255) 0px 0px 0px 2px inset; white-space: nowrap; vertical-align: middle; }
.md-comment { color: rgb(162, 127, 3); opacity: 0.6; font-family: var(--monospace); }
code { text-align: left; vertical-align: initial; }
a.md-print-anchor { white-space: pre !important; border-width: initial !important; border-style: none !important; border-color: initial !important; display: inline-block !important; position: absolute !important; width: 1px !important; right: 0px !important; outline: 0px !important; background: 0px 0px !important; text-decoration: initial !important; text-shadow: initial !important; }
.os-windows.monocolor-emoji .md-emoji { font-family: "Segoe UI Symbol", sans-serif; }
.md-diagram-panel > svg { max-width: 100%; }
[lang="flow"] svg, [lang="mermaid"] svg { max-width: 100%; height: auto; }
[lang="mermaid"] .node text { font-size: 1rem; }
table tr th { border-bottom: 0px; }
video { max-width: 100%; display: block; margin: 0px auto; }
iframe { max-width: 100%; width: 100%; border: none; }
.highlight td, .highlight tr { border: 0px; }
mark { background: rgb(255, 255, 0); color: rgb(0, 0, 0); }
.md-html-inline .md-plain, .md-html-inline strong, mark .md-inline-math, mark strong { color: inherit; }
.md-expand mark .md-meta { opacity: 0.3 !important; }
mark .md-meta { color: rgb(0, 0, 0); }
@media print {
.typora-export h1, .typora-export h2, .typora-export h3, .typora-export h4, .typora-export h5, .typora-export h6 { break-inside: avoid; }
}
.md-diagram-panel .messageText { stroke: none !important; }
.md-diagram-panel .start-state { fill: var(--node-fill); }
.md-diagram-panel .edgeLabel rect { opacity: 1 !important; }
.md-fences.md-fences-math { font-size: 1em; }
.md-fences-advanced:not(.md-focus) { padding: 0px; white-space: nowrap; border: 0px; }
.md-fences-advanced:not(.md-focus) { background: inherit; }
.typora-export-show-outline .typora-export-content { max-width: 1440px; margin: auto; display: flex; flex-direction: row; }
.typora-export-sidebar { width: 300px; font-size: 0.8rem; margin-top: 80px; margin-right: 18px; }
.typora-export-show-outline #write { --webkit-flex:2; flex: 2 1 0%; }
.typora-export-sidebar .outline-content { position: fixed; top: 0px; max-height: 100%; overflow: hidden auto; padding-bottom: 30px; padding-top: 60px; width: 300px; }
@media screen and (max-width: 1024px) {
.typora-export-sidebar, .typora-export-sidebar .outline-content { width: 240px; }
}
@media screen and (max-width: 800px) {
.typora-export-sidebar { display: none; }
}
2023-12-25 05:50:42 +00:00
.outline-content li, .outline-content ul { margin-left: 0px; margin-right: 0px; padding-left: 0px; padding-right: 0px; list-style: none; overflow-wrap: anywhere; }
2022-06-02 06:34:10 +00:00
.outline-content ul { margin-top: 0px; margin-bottom: 0px; }
.outline-content strong { font-weight: 400; }
.outline-expander { width: 1rem; height: 1.42857rem; position: relative; display: table-cell; vertical-align: middle; cursor: pointer; padding-left: 4px; }
.outline-expander::before { content: ""; position: relative; font-family: Ionicons; display: inline-block; font-size: 8px; vertical-align: middle; }
.outline-item { padding-top: 3px; padding-bottom: 3px; cursor: pointer; }
.outline-expander:hover::before { content: ""; }
.outline-h1 > .outline-item { padding-left: 0px; }
.outline-h2 > .outline-item { padding-left: 1em; }
.outline-h3 > .outline-item { padding-left: 2em; }
.outline-h4 > .outline-item { padding-left: 3em; }
.outline-h5 > .outline-item { padding-left: 4em; }
.outline-h6 > .outline-item { padding-left: 5em; }
.outline-label { cursor: pointer; display: table-cell; vertical-align: middle; text-decoration: none; color: inherit; }
.outline-label:hover { text-decoration: underline; }
.outline-item:hover { border-color: rgb(245, 245, 245); background-color: var(--item-hover-bg-color); }
.outline-item:hover { margin-left: -28px; margin-right: -28px; border-left: 28px solid transparent; border-right: 28px solid transparent; }
.outline-item-single .outline-expander::before, .outline-item-single .outline-expander:hover::before { display: none; }
.outline-item-open > .outline-item > .outline-expander::before { content: ""; }
.outline-children { display: none; }
.info-panel-tab-wrapper { display: none; }
.outline-item-open > .outline-children { display: block; }
.typora-export .outline-item { padding-top: 1px; padding-bottom: 1px; }
.typora-export .outline-item:hover { margin-right: -8px; border-right: 8px solid transparent; }
.typora-export .outline-expander::before { content: "+"; font-family: inherit; top: -1px; }
.typora-export .outline-expander:hover::before, .typora-export .outline-item-open > .outline-item > .outline-expander::before { content: ""; }
.typora-export-collapse-outline .outline-children { display: none; }
.typora-export-collapse-outline .outline-item-open > .outline-children, .typora-export-no-collapse-outline .outline-children { display: block; }
.typora-export-no-collapse-outline .outline-expander::before { content: "" !important; }
.typora-export-show-outline .outline-item-active > .outline-item .outline-label { font-weight: 700; }
.md-inline-math-container mjx-container { zoom: 0.95; }
2022-11-26 08:35:55 +00:00
mjx-container { break-inside: avoid; }
2022-06-02 06:34:10 +00:00
.CodeMirror { height: auto; }
.CodeMirror.cm-s-inner { background: inherit; }
.CodeMirror-scroll { overflow: auto hidden; z-index: 3; }
.CodeMirror-gutter-filler, .CodeMirror-scrollbar-filler { background-color: rgb(255, 255, 255); }
.CodeMirror-gutters { border-right: 1px solid rgb(221, 221, 221); background: inherit; white-space: nowrap; }
.CodeMirror-linenumber { padding: 0px 3px 0px 5px; text-align: right; color: rgb(153, 153, 153); }
.cm-s-inner .cm-keyword { color: rgb(119, 0, 136); }
.cm-s-inner .cm-atom, .cm-s-inner.cm-atom { color: rgb(34, 17, 153); }
.cm-s-inner .cm-number { color: rgb(17, 102, 68); }
.cm-s-inner .cm-def { color: rgb(0, 0, 255); }
.cm-s-inner .cm-variable { color: rgb(0, 0, 0); }
.cm-s-inner .cm-variable-2 { color: rgb(0, 85, 170); }
.cm-s-inner .cm-variable-3 { color: rgb(0, 136, 85); }
.cm-s-inner .cm-string { color: rgb(170, 17, 17); }
.cm-s-inner .cm-property { color: rgb(0, 0, 0); }
.cm-s-inner .cm-operator { color: rgb(152, 26, 26); }
.cm-s-inner .cm-comment, .cm-s-inner.cm-comment { color: rgb(170, 85, 0); }
.cm-s-inner .cm-string-2 { color: rgb(255, 85, 0); }
.cm-s-inner .cm-meta { color: rgb(85, 85, 85); }
.cm-s-inner .cm-qualifier { color: rgb(85, 85, 85); }
.cm-s-inner .cm-builtin { color: rgb(51, 0, 170); }
.cm-s-inner .cm-bracket { color: rgb(153, 153, 119); }
.cm-s-inner .cm-tag { color: rgb(17, 119, 0); }
.cm-s-inner .cm-attribute { color: rgb(0, 0, 204); }
.cm-s-inner .cm-header, .cm-s-inner.cm-header { color: rgb(0, 0, 255); }
.cm-s-inner .cm-quote, .cm-s-inner.cm-quote { color: rgb(0, 153, 0); }
.cm-s-inner .cm-hr, .cm-s-inner.cm-hr { color: rgb(153, 153, 153); }
.cm-s-inner .cm-link, .cm-s-inner.cm-link { color: rgb(0, 0, 204); }
.cm-negative { color: rgb(221, 68, 68); }
.cm-positive { color: rgb(34, 153, 34); }
.cm-header, .cm-strong { font-weight: 700; }
.cm-del { text-decoration: line-through; }
.cm-em { font-style: italic; }
.cm-link { text-decoration: underline; }
.cm-error { color: red; }
.cm-invalidchar { color: red; }
.cm-constant { color: rgb(38, 139, 210); }
.cm-defined { color: rgb(181, 137, 0); }
div.CodeMirror span.CodeMirror-matchingbracket { color: rgb(0, 255, 0); }
div.CodeMirror span.CodeMirror-nonmatchingbracket { color: rgb(255, 34, 34); }
.cm-s-inner .CodeMirror-activeline-background { background: inherit; }
.CodeMirror { position: relative; overflow: hidden; }
.CodeMirror-scroll { height: 100%; outline: 0px; position: relative; box-sizing: content-box; background: inherit; }
.CodeMirror-sizer { position: relative; }
.CodeMirror-gutter-filler, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler, .CodeMirror-vscrollbar { position: absolute; z-index: 6; display: none; outline: 0px; }
.CodeMirror-vscrollbar { right: 0px; top: 0px; overflow: hidden; }
.CodeMirror-hscrollbar { bottom: 0px; left: 0px; overflow: auto hidden; }
.CodeMirror-scrollbar-filler { right: 0px; bottom: 0px; }
.CodeMirror-gutter-filler { left: 0px; bottom: 0px; }
.CodeMirror-gutters { position: absolute; left: 0px; top: 0px; padding-bottom: 10px; z-index: 3; overflow-y: hidden; }
.CodeMirror-gutter { white-space: normal; height: 100%; box-sizing: content-box; padding-bottom: 30px; margin-bottom: -32px; display: inline-block; }
.CodeMirror-gutter-wrapper { position: absolute; z-index: 4; background: 0px 0px !important; border: none !important; }
.CodeMirror-gutter-background { position: absolute; top: 0px; bottom: 0px; z-index: 4; }
.CodeMirror-gutter-elt { position: absolute; cursor: default; z-index: 4; }
.CodeMirror-lines { cursor: text; }
.CodeMirror pre { border-radius: 0px; border-width: 0px; background: 0px 0px; font-family: inherit; font-size: inherit; margin: 0px; white-space: pre; overflow-wrap: normal; color: inherit; z-index: 2; position: relative; overflow: visible; }
.CodeMirror-wrap pre { overflow-wrap: break-word; white-space: pre-wrap; word-break: normal; }
.CodeMirror-code pre { border-right: 30px solid transparent; width: fit-content; }
.CodeMirror-wrap .CodeMirror-code pre { border-right: none; width: auto; }
.CodeMirror-linebackground { position: absolute; inset: 0px; z-index: 0; }
.CodeMirror-linewidget { position: relative; z-index: 2; overflow: auto; }
.CodeMirror-wrap .CodeMirror-scroll { overflow-x: hidden; }
.CodeMirror-measure { position: absolute; width: 100%; height: 0px; overflow: hidden; visibility: hidden; }
.CodeMirror-measure pre { position: static; }
.CodeMirror div.CodeMirror-cursor { position: absolute; visibility: hidden; border-right: none; width: 0px; }
.CodeMirror div.CodeMirror-cursor { visibility: hidden; }
.CodeMirror-focused div.CodeMirror-cursor { visibility: inherit; }
.cm-searching { background: rgba(255, 255, 0, 0.4); }
span.cm-underlined { text-decoration: underline; }
span.cm-strikethrough { text-decoration: line-through; }
.cm-tw-syntaxerror { color: rgb(255, 255, 255); background-color: rgb(153, 0, 0); }
.cm-tw-deleted { text-decoration: line-through; }
.cm-tw-header5 { font-weight: 700; }
.cm-tw-listitem:first-child { padding-left: 10px; }
.cm-tw-box { border-style: solid; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-color: inherit; border-top-width: 0px !important; }
.cm-tw-underline { text-decoration: underline; }
@media print {
.CodeMirror div.CodeMirror-cursor { visibility: hidden; }
}
:root {
--side-bar-bg-color: #fafafa;
--control-text-color: #777;
}
2023-12-25 05:50:42 +00:00
@include-when-export url(https://fonts.googleapis.com/css?family=Open+Sans:400italic,700italic,700,400&subset=latin,latin-ext);
2022-06-02 06:34:10 +00:00
/* open-sans-regular - latin-ext_latin */
/* open-sans-italic - latin-ext_latin */
/* open-sans-700 - latin-ext_latin */
/* open-sans-700italic - latin-ext_latin */
html {
font-size: 16px;
-webkit-font-smoothing: antialiased;
}
body {
font-family: "Open Sans","Clear Sans", "Helvetica Neue", Helvetica, Arial, 'Segoe UI Emoji', sans-serif;
color: rgb(51, 51, 51);
line-height: 1.6;
}
#write {
max-width: 860px;
margin: 0 auto;
padding: 30px;
padding-bottom: 100px;
}
@media only screen and (min-width: 1400px) {
#write {
max-width: 1024px;
}
}
@media only screen and (min-width: 1800px) {
#write {
max-width: 1200px;
}
}
#write > ul:first-child,
#write > ol:first-child{
margin-top: 30px;
}
a {
color: #4183C4;
}
h1,
h2,
h3,
h4,
h5,
h6 {
position: relative;
margin-top: 1rem;
margin-bottom: 1rem;
font-weight: bold;
line-height: 1.4;
cursor: text;
}
h1:hover a.anchor,
h2:hover a.anchor,
h3:hover a.anchor,
h4:hover a.anchor,
h5:hover a.anchor,
h6:hover a.anchor {
text-decoration: none;
}
h1 tt,
h1 code {
font-size: inherit;
}
h2 tt,
h2 code {
font-size: inherit;
}
h3 tt,
h3 code {
font-size: inherit;
}
h4 tt,
h4 code {
font-size: inherit;
}
h5 tt,
h5 code {
font-size: inherit;
}
h6 tt,
h6 code {
font-size: inherit;
}
h1 {
font-size: 2.25em;
line-height: 1.2;
border-bottom: 1px solid #eee;
}
h2 {
font-size: 1.75em;
line-height: 1.225;
border-bottom: 1px solid #eee;
}
/*@media print {
.typora-export h1,
.typora-export h2 {
border-bottom: none;
padding-bottom: initial;
}
.typora-export h1::after,
.typora-export h2::after {
content: "";
display: block;
height: 100px;
margin-top: -96px;
border-top: 1px solid #eee;
}
}*/
h3 {
font-size: 1.5em;
line-height: 1.43;
}
h4 {
font-size: 1.25em;
}
h5 {
font-size: 1em;
}
h6 {
font-size: 1em;
color: #777;
}
p,
blockquote,
ul,
ol,
dl,
table{
margin: 0.8em 0;
}
li>ol,
li>ul {
margin: 0 0;
}
hr {
height: 2px;
padding: 0;
margin: 16px 0;
background-color: #e7e7e7;
border: 0 none;
overflow: hidden;
box-sizing: content-box;
}
li p.first {
display: inline-block;
}
ul,
ol {
padding-left: 30px;
}
ul:first-child,
ol:first-child {
margin-top: 0;
}
ul:last-child,
ol:last-child {
margin-bottom: 0;
}
blockquote {
border-left: 4px solid #dfe2e5;
padding: 0 15px;
color: #777777;
}
blockquote blockquote {
padding-right: 0;
}
table {
padding: 0;
word-break: initial;
}
table tr {
border: 1px solid #dfe2e5;
margin: 0;
padding: 0;
}
table tr:nth-child(2n),
thead {
background-color: #f8f8f8;
}
table th {
font-weight: bold;
border: 1px solid #dfe2e5;
border-bottom: 0;
margin: 0;
padding: 6px 13px;
}
table td {
border: 1px solid #dfe2e5;
margin: 0;
padding: 6px 13px;
}
table th:first-child,
table td:first-child {
margin-top: 0;
}
table th:last-child,
table td:last-child {
margin-bottom: 0;
}
.CodeMirror-lines {
padding-left: 4px;
}
.code-tooltip {
box-shadow: 0 1px 1px 0 rgba(0,28,36,.3);
border-top: 1px solid #eef2f2;
}
.md-fences,
code,
tt {
border: 1px solid #e7eaed;
background-color: #f8f8f8;
border-radius: 3px;
padding: 0;
padding: 2px 4px 0px 4px;
font-size: 0.9em;
}
code {
background-color: #f3f4f4;
padding: 0 2px 0 2px;
}
.md-fences {
margin-bottom: 15px;
margin-top: 15px;
padding-top: 8px;
padding-bottom: 6px;
}
.md-task-list-item > input {
margin-left: -1.3em;
}
@media print {
html {
font-size: 13px;
}
pre {
page-break-inside: avoid;
word-wrap: break-word;
}
}
.md-fences {
background-color: #f8f8f8;
}
#write pre.md-meta-block {
padding: 1rem;
font-size: 85%;
line-height: 1.45;
background-color: #f7f7f7;
border: 0;
border-radius: 3px;
color: #777777;
margin-top: 0 !important;
}
.mathjax-block>.code-tooltip {
bottom: .375rem;
}
.md-mathjax-midline {
background: #fafafa;
}
#write>h3.md-focus:before{
left: -1.5625rem;
top: .375rem;
}
#write>h4.md-focus:before{
left: -1.5625rem;
top: .285714286rem;
}
#write>h5.md-focus:before{
left: -1.5625rem;
top: .285714286rem;
}
#write>h6.md-focus:before{
left: -1.5625rem;
top: .285714286rem;
}
.md-image>.md-meta {
/*border: 1px solid #ddd;*/
border-radius: 3px;
padding: 2px 0px 0px 4px;
font-size: 0.9em;
color: inherit;
}
.md-tag {
color: #a7a7a7;
opacity: 1;
}
.md-toc {
margin-top:20px;
padding-bottom:20px;
}
.sidebar-tabs {
border-bottom: none;
}
#typora-quick-open {
border: 1px solid #ddd;
background-color: #f8f8f8;
}
#typora-quick-open-item {
background-color: #FAFAFA;
border-color: #FEFEFE #e5e5e5 #e5e5e5 #eee;
border-style: solid;
border-width: 1px;
}
/** focus mode */
.on-focus-mode blockquote {
border-left-color: rgba(85, 85, 85, 0.12);
}
header, .context-menu, .megamenu-content, footer{
font-family: "Segoe UI", "Arial", sans-serif;
}
.file-node-content:hover .file-node-icon,
.file-node-content:hover .file-node-open-state{
visibility: visible;
}
.mac-seamless-mode #typora-sidebar {
background-color: #fafafa;
background-color: var(--side-bar-bg-color);
}
.md-lang {
color: #b4654d;
}
/*.html-for-mac {
--item-hover-bg-color: #E6F0FE;
}*/
#md-notification .btn {
border: 0;
}
.dropdown-menu .divider {
border-color: #e5e5e5;
opacity: 0.4;
}
.ty-preferences .window-content {
background-color: #fafafa;
}
.ty-preferences .nav-group-item.active {
color: white;
background: #999;
}
.menu-item-container a.menu-style-btn {
background-color: #f5f8fa;
background-image: linear-gradient( 180deg , hsla(0, 0%, 100%, 0.8), hsla(0, 0%, 100%, 0));
}
2022-06-08 07:52:50 +00:00
</style><title>可视化大屏系统开发及使用手册</title>
2021-07-10 09:34:53 +00:00
</head>
2022-06-02 06:34:10 +00:00
<body class='typora-export os-windows typora-export-show-outline typora-export-collapse-outline'><div class='typora-export-content'>
2023-12-25 05:50:42 +00:00
<div class="typora-export-sidebar"><div class="outline-content"><li class="outline-item-wrapper outline-h2"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#0-前言说明">0 前言说明</a></div><ul class="outline-children"><li class="outline-item-wrapper outline-h3 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#01-编译说明">0.1 编译说明</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h3 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#02-版本说明">0.2 版本说明</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h3 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#03-相关站点">0.3 相关站点</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h3 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#04-功能特点">0.4 功能特点</a></div><ul class="outline-children"></ul></li></ul></li><li class="outline-item-wrapper outline-h2"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#1-操作说明">1 操作说明</a></div><ul class="outline-children"><li class="outline-item-wrapper outline-h3"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#11-使用方法">1.1 使用方法</a></div><ul class="outline-children"><li class="outline-item-wrapper outline-h4"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#111-启动窗体">1.1.1 启动窗体</a></div><ul class="outline-children"><li class="outline-item-wrapper outline-h5 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#1111-大屏系统">1.1.1.1 大屏系统</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h5 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#1112-模块演示">1.1.1.2 模块演示</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h5 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#1113-控件演示">1.1.1.3 控件演示</a></div><ul class="outline-children"></ul></li></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#112-系统菜单">1.1.2 系统菜单</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#113-模块菜单">1.1.3 模块菜单</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#114-布局切换">1.1.4 布局切换</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#115-新建布局">1.1.5 新建布局</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#116-全局换肤">1.1.6 全局换肤</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#117-模块拖动">1.1.7 模块拖动</a></div><ul class="outline-chil
2022-07-08 09:23:44 +00:00
<span> </span><img src="snap/1-1-1-1.jpg" referrerpolicy="no-referrer"></p><h5 id='1111-大屏系统'><span>1.1.1.1 大屏系统</span></h5><p><span> </span><img src="snap/1-1-1-2.jpg" referrerpolicy="no-referrer"></p><h5 id='1112-模块演示'><span>1.1.1.2 模块演示</span></h5><p><span> </span><img src="snap/1-1-1-3.jpg" referrerpolicy="no-referrer"></p><h5 id='1113-控件演示'><span>1.1.1.3 控件演示</span></h5><p><span> </span><img src="snap/1-1-1-4.jpg" referrerpolicy="no-referrer"></p><h4 id='112-系统菜单'><span>1.1.2 系统菜单</span></h4><p><span> </span><img src="snap/1-1-2-1.jpg" referrerpolicy="no-referrer">
2022-06-02 06:34:10 +00:00
<span> </span><img src="snap/1-1-2-2.jpg" referrerpolicy="no-referrer"></p><p><span>在大屏的顶部中间标题栏或者子模块以外的标题栏,鼠标右键弹出的是系统的菜单,包括布局切换和样式切换等。</span></p><h4 id='113-模块菜单'><span>1.1.3 模块菜单</span></h4><p><span> </span><img src="snap/1-1-3-1.jpg" referrerpolicy="no-referrer">
2023-12-25 05:50:42 +00:00
<span> </span><img src="snap/1-1-3-2.jpg" referrerpolicy="no-referrer"></p><p><span>在模块的标题栏鼠标右键弹出的是模块可视化的菜单这个是Qt内置生成的加载了多少个子模块就会生成多少个菜单项可以对每个模块进行显示隐藏切换。</span></p><h4 id='114-布局切换'><span>1.1.4 布局切换</span></h4><p><span>在弹出的系统菜单选择布局方案,在弹出的二级菜单选择默认已经设置好的布局方案,直接切换即可。</span></p><h4 id='115-新建布局'><span>1.1.5 新建布局</span></h4><p><span>在弹出的系统菜单选择新建布局,在弹出的框中输入布局名称,确认后,自由拖动调整模块位置,打开模块、隐藏模块,之后单击保存布局即可。</span></p><h4 id='116-全局换肤'><span>1.1.6 全局换肤</span></h4><p><span>在弹出的系统菜单选择配色方案,在弹出的二级菜单选择对应的配色方案,默认有四种:紫色风格、蓝色风格、深蓝风格、黑色风格。</span></p><h4 id='117-模块拖动'><span>1.1.7 模块拖动</span></h4><p><span>鼠标移动到子模块的标题栏,鼠标按下可以拖动这个模块到任意位置,模块也可以拖动独立位置展示,也可以嵌入到对应布局中,拖动好位置以后自动保存到布局方案,下次启动自动应用。双击模块标题栏可以剥离窗体使之悬浮。</span></p><h4 id='118-调整间距'><span>1.1.8 调整间距</span></h4><p><span>鼠标移动到模块与模块的边缘,鼠标变成调整间距样式,可以左右或者上下拉动,调整好间距以后自动保存到布局方案,下次启动自动应用。</span></p><h3 id='12-系统设置'><span>1.2 系统设置</span></h3><p><span> </span><img src="snap/1-2-0.jpg" referrerpolicy="no-referrer"></p><p><strong><span>系统设置中的参数,可能会不定期做调整和修改及增加,下面的图示和参数描述未必全部一致,以最新的为准。</span></strong></p><h4 id='121-基本设置'><span>1.2.1 基本设置</span></h4><p><span> </span><img src="snap/1-2-1.jpg" referrerpolicy="no-referrer"></p><p><strong><span>参数说明</span></strong></p><ol start='' ><li><p><span>开机启动:默认关闭,开启后软件会随系统启动而启动。</span></p></li><li><p><span>模块拖动:默认开启,开启后模块可以自由拖动到合适的位置松开,一般在布局固定后在关闭,防止使用者在现场又托乱了。</span></p></li><li><p><span>切左下角:开启裁掉左下角以后,左侧底部和整体底部合并为一体,作为全局底部的一部分,就可以拖动模块到左侧底部,否则左侧底部作为左侧的一部分。</span></p></li><li><p><span>切右下角:开启裁掉右下角以后,右侧底部和整体底部合并为一体,作为全局底部的一部分,就可以拖动模块到右侧底部,否则右侧底部作为右侧的一部分。</span></p></li><li><p><span>定位线条系统中曲线图表内置了定位线条比如1月份方便查看可以开启。</span></p></li><li><p><span>百分符号系统中曲线图表Y轴有时候需要按照 100% 后面带百分比符号显示。</span></p></li><li><p><span>隐藏鼠标鼠标未操作多久自动隐藏鼠标指针默认5秒钟。</span></p></li><li><p><span>启动窗体:选择程序运行的启动窗体,默认大屏系统,还可选择控件演示、模块演示。</span></p></li><li><p><span>工作模式:默认工作模式是模拟数据,还可以选择数据库采集、串口采集(未实现)、网络采集(未实现)、网络请求。</span></p></li><li><p><span>地图样式:可选择静态图片、闪烁效果、迁徙效果、世界地图、区域地图多种样式,如果没有开启浏览器模块则自动采用静态图片的方式,区域地图默认是江西省吉安市,可以在代码中修改。</span></p></li><li><p><span>布局方案:和系统右键菜单中的布局方案功能一样。</span></p></li><li><p><sp
2022-11-26 08:35:55 +00:00
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">7</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//模拟数据采用随机数据 其他采用调用函数接口查询和请求数据</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">8</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">if</span> (<span class="cm-variable">AppConfig::WorkMode</span> <span class="cm-operator">==</span> <span class="cm-string">"timer"</span>) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">9</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable-3">double</span> <span class="cm-variable">min</span> <span class="cm-operator">=</span> <span class="cm-number">1</span>, <span class="cm-variable">max</span> <span class="cm-operator">=</span> <span class="cm-number">50</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">10</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">vdouble</span> <span class="cm-variable">value1</span>, <span class="cm-variable">value2</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">11</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-keyword">for</span> (<span class="cm-variable-3">int</span> <span class="cm-variable">i</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>; <span class="cm-variable">i</span> <span class="cm-operator">&lt;</span> <span class="cm-variable">rowNames1</span>.<span class="cm-variable">count</span>(); <span class="cm-operator">++</span><span class="cm-variable">i</span>) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">12</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">value1</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-variable">QUIHelper::getRandValue</span>(<span class="cm-variable">min</span>, <span class="cm-variable">max</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">13</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">value2</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-variable">QUIHelper::getRandValue</span>(<span class="cm-variable">min</span>, <span class="cm-variable">max</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div
2022-06-02 06:34:10 +00:00
<span> </span><img src="snap/1-3-2.jpg" referrerpolicy="no-referrer">
<span>sql server数据库的配置规则下面的链接只是参考基本上正常电脑安装好以后都不需要下面的配置。</span>
<a href='https://blog.csdn.net/mozhi111/article/details/80281388' target='_blank' class='url'>https://blog.csdn.net/mozhi111/article/details/80281388</a>
2023-12-25 05:50:42 +00:00
<a href='https://blog.csdn.net/happymagic/article/details/8673476' target='_blank' class='url'>https://blog.csdn.net/happymagic/article/details/8673476</a></p><p><span>远程访问sql server数据库需要在运行软件的电脑上也需要配置数据源不然很可能无法访问。</span></p><p><strong><span>sql server数据库配置步骤</span></strong></p><ol start='' ><li><p><span>第一步安装好sql server数据库比如sql server 2014设置混合验证模式并设置密码。</span></p></li><li><p><span>第二步打开sql server management studio左侧新建数据库bigscreen。</span></p></li><li><p><span>第三步新建odbc数据源cmd执行命令odbcad32打开数据源配置命名为bigscreen关联到数据库bigscreen。</span>
<span>切记Qt中连接sqlserver数据库采用的odbc方式数据库名填写的是数据源中的名称而不是数据库中的数据库名称比如数据源名字是aaa关联到数据库bbb连接的数据库名称是填写aaa而不是bbb。</span></p></li></ol><p><span>安装PostgreSQL数据库之后默认只能本地访问连接。如果想在其他主机上访问PostgreSQL数据库服务器就需要进行相应的配置。</span>
2022-06-02 06:34:10 +00:00
<a href='https://blog.csdn.net/weixin_36816337/article/details/81739819' target='_blank' class='url'>https://blog.csdn.net/weixin_36816337/article/details/81739819</a>
<span> </span><img src="snap/1-3-3.jpg" referrerpolicy="no-referrer">
2023-12-25 05:50:42 +00:00
<span>人大金仓数据库kingbase其实就是postgresql数据库改的如果是WIN10系统建议安装在系统盘以外不然没有权限导致奇奇怪怪的问题。</span></p><p><strong><span>特别提示</span></strong></p><ul><li><p><span>数据库有位数区分如果是32位的qt对应打包目录要放32位的数据库的dll比如放32位的libmysql.dll不然会提示找不到驱动。</span></p></li><li><p><span>无论32位还是64位的qt程序都能连接64位的数据库。 </span></p></li><li><p><span>意思是在开发阶段必须放正确位数的dll而数据库只需要安装64位的即可。</span></p></li><li><p><span>sqlserver数据库采用odbc数据源的方式进行连接而且是微软亲生的估计在系统层做了无微不至的关怀qt程序发布的时候啥也不用带。</span></p></li></ul><h4 id='133-串口采集'><span>1.3.3 串口采集</span></h4><p><span>需要定制协议比如RS232、RS485、Modbus、Mqtt等</span></p><h4 id='134-网络采集'><span>1.3.4 网络采集</span></h4><p><span>需要定制协议比如tcp client、tcp server、udp client、udp server、websocket等。</span></p><h4 id='135-网络请求'><span>1.3.5 网络请求</span></h4><p><span> </span><img src="snap/1-3-5.jpg" referrerpolicy="no-referrer"></p><p><span>找到bigscreen可执行文件所在目录下的httpserver文件双击运行切换到网络请求服务器页面回复数据选择文件内容单击启动服务器左侧消息栏可以看到实时打印的数据从json文件读取的数据实际中可以是从数据库中采集的数据等。网络请求客户端/服务器工具httpserver也是纯Qt编写的工具。</span></p><p><strong><span>功能特点</span></strong></p><ol start='' ><li><p><span>支持多个客户端连接并发同时处理100个毫无压力。</span></p></li><li><p><span>可设置http请求是长连接还是短连接默认长连接。</span></p></li><li><p><span>支持多种回复数据格式其中包括网页内容、json数据等。</span></p></li><li><p><span>服务端示例中同时包含读取文件回复、读取数据库回复。</span></p></li><li><p><span>支持8种配色方案暗黑、灰黑、深绿、浅黄、深蓝、深黑、暗蓝、默认</span></p></li><li><p><span>客户端可指定请求地址,服务端可指定网卡和端口进行监听。</span></p></li><li><p><span>所有请求和连接都有计数所有在线请求的IP和端口都显示在表格中。</span></p></li><li><p><span>可以提供一个简易的网页配置服务包括交互作为设备的web配置。</span></p></li><li><p><span>可自由拓展增加权限校验等作为一个http请求服务器。</span></p></li><li><p><span>纯Qt实现代码框架整洁注释完整支持任意Qt版本、任意编译器、任意操作系统。</span></p></li></ol><h4 id='136-请求格式'><span>1.3.6 请求格式</span></h4><p><span>请求地址:</span><a href='http://127.0.0.1:6000' target='_blank' class='url'>http://127.0.0.1:6000</a><span> 可以自行在系统设置中更改。</span></p><h5 id='1361-请求数据'><span>1.3.6.1 请求数据</span></h5><p><span>其他表请求格式完全一致。</span>
<span>tag=t_1_1_mold_prod_total&amp;tableName=t_1_1_mold_prod_total&amp;columnName=name,prod_1,prod_2</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>名称</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>tag</span></td><td style='text-align:left;' ><span>标识符,用于服务端接收到请求后按照这个标识符返回数据,这里内容填的是具体的表名,方便收到数据直接解析并发送信号到对应模块窗体显示数据。</span></td></tr><tr><td style='text-align:left;' ><span>tableName</span></td><td style='text-align:left;' ><span>要查询的表名。</span></td></tr><tr><td style='text-align:left;' ><span>columnName</span></td><td style='text-align:left;' ><span>对应表的字段名称集合,用英文逗号隔开。</span></td></tr></tbody></table></figure><h5 id='1362-返回数据'><span>1.3.6.2 返回数据</span></h5><pre class="md-fences md-end-block md-fences-with-lineno ty-contain-cm modeLoaded" spellcheck="false" lang="json" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="json"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.51875px; left: 44px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 36px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre><div class="CodeMirror-linenumber CodeMirror-gutter-elt"><div>19</div></div></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: -36px; width: 36px;"></div><div class="CodeMirror-gutter-wrapper CodeMirror-activeline-gutter" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">1</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">{</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">2</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-tab" role="presentation" cm-text=" "> </span><span class="cm-string cm-property">"tag"</span>: <span class="cm-string">"t_1_1_mold_prod_total"</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">3</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-tab" role="presentation" cm-text=" "> </span><span class="cm-string cm-property">"result"</span>: [{</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">4</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation"
2022-06-02 06:34:10 +00:00
<span>如果是需要对接自己的系统,可能涉及到部分数据不一致的情况,你可以:</span>
<span>第一:尽量用现有的表,现有的表各种各样都有,你找到你类似的往里面填数据就行。</span>
2023-12-25 05:50:42 +00:00
<span>第二:如果没有合适的表,则需要调整对应的模块代码。</span></p><h3 id='21-产量汇总模块'><span>2.1 产量汇总模块</span></h3><p><span> </span><img src="snap/2-1-0.jpg" referrerpolicy="no-referrer"></p><p><span>子模块表名对应表:</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>子模块标题</span></th><th style='text-align:left;' ><span>子模块表名</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>模具产量</span></td><td style='text-align:left;' ><span>t_1_1_mold_prod_total</span></td></tr><tr><td style='text-align:left;' ><span>每月模具产量趋势图</span></td><td style='text-align:left;' ><span>t_1_2_mold_prod_monthly</span></td></tr><tr><td style='text-align:left;' ><span>零件产量</span></td><td style='text-align:left;' ><span>t_1_3_wp_prod_total</span></td></tr><tr><td style='text-align:left;' ><span>每月零件产量趋势图</span></td><td style='text-align:left;' ><span>t_1_4_wp_prod_monthly</span></td></tr></tbody></table></figure><h4 id='211-模具产量'><span>2.1.1 模具产量</span></h4><p><span> </span><img src="snap/2-1-1.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_1_1_mold_prod_total</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>name</span></td><td style='text-align:left;' ><span>名称</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' ><span>不为空</span></td></tr><tr><td style='text-align:left;' ><span>prod_1</span></td><td style='text-align:left;' ><span>系列1</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>prod_2</span></td><td style='text-align:left;' ><span>系列2</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' >&nbsp;</td></tr></tbody></table></figure><p><span>默认数据:</span></p><figure class='table-figure'><table><thead><tr><th><span>internal_id</span></th><th><span>name</span></th><th><span>prod_1</span></th><th><span>prod_2</span></th></tr></thead><tbody><tr><td><span>1</span></td><td><span>设变</span></td><td><span>14</span></td><td><span>12</span></td></tr><tr><td><span>2</span></td><td><span>修模</span></td><td><span>20</span></td><td><span>25</span></td></tr><tr><td><span>3</span></td><td><span>新模</span></td><td><span>40</span></td><td><span>25</span></td></tr></tbody></table></figure><h4 id='212-每月模具产量趋势图'><span>2.1.2 每月模具产量趋势图</span></h4><p><span> </span><img src="snap/2-1-2.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_1_2_mold_prod_monthly</span><span> </span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span>
<span>1</span><span> </span><span>60</span><span> </span><span>25</span><span> </span><span>15</span></p><h4 id='243-加工中模具数量'><span>2.4.3 加工中模具数量</span></h4><p><span> </span><img src="snap/2-4-3.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_4_3_mold_processing_num</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>mold_processing_number</span></td><td style='text-align:left;' ><span>加工中数量</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>不为空</span></td></tr></tbody></table></figure><p><span>默认数据87</span></p><h3 id='25-负荷分布模块'><span>2.5 负荷分布模块</span></h3><p><span> </span><img src="snap/2-5-0.jpg" referrerpolicy="no-referrer"></p><p><span>子模块表名对应表:</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>子模块标题</span></th><th style='text-align:left;' ><span>子模块表名</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>工序计划负荷</span></td><td style='text-align:left;' ><span>t_5_1_work_load</span></td></tr><tr><td style='text-align:left;' ><span>当日负荷</span></td><td style='text-align:left;' ><span>t_5_2_work_load_today</span></td></tr><tr><td style='text-align:left;' ><span>负荷百分比</span></td><td style='text-align:left;' ><span>t_5_3_work_load_percent</span></td></tr></tbody></table></figure><h4 id='251-工序计划负荷'><span>2.5.1 工序计划负荷</span></h4><p><span> </span><img src="snap/2-5-1.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_5_1_work_load</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>process_name</span></td><td style='text-align:left;' ><span>工序名称</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>work_load_1</span></td><td style='text-align:left;' ><span>第1天负荷</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>work_load_x</span></td><td style='text-align:left;' ><span>第x天负荷</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>work_load_7</span></td><td style='text-align:left;' ><span>第7天负荷</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr></tbody></table></figure>
<span>这个设计很巧妙,相当于动态的日期和数据,日期作为标题。</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>date_1</span></td><td style='text-align:left;' ><span>第1天日期</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>date_2</span></td><td style='text-align:left;' ><span>第2天日期</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>date_3</span></td><td style='text-align:left;' ><span>第3天日期</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>date_4</span></td><td style='text-align:left;' ><span>第4天日期</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>date_5</span></td><td style='text-align:left;' ><span>第5天日期</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>date_6</span></td><td style='text-align:left;' ><span>第6天日期</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>date_7</span></td><td style='text-align:left;' ><span>第7天日期</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr></tbody></table></figure><p><span>默认数据:</span></p><figure class='table-figure'><table><thead><tr><th><span>internal_id</span></th><th><span>date_1</span></th><th><span>date_2</span></th><th><span>date_3</span></th><th><span>date_4</span></th><th><span>date_5</span></th><th><span>date_6</span></th><th><span>date_7</span></th></tr></thead><tbody><tr><td><span>1</span></td><td><span>2019-04-30</span></td><td><span>2019-05-01</span></td><td><span>2019-05-02</span></td><td><span>2019-05-03</span></td><td><span>2019-05-04</span></td><td><span>2019-05-05</span></td><td><span>2019-05-06</span></td></tr></tbody></table></figure><h4 id='252-当日负荷'><span>2.5.2 当日负荷</span></h4><p><span> </span><img src="snap/2-5-2.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_5_2_work_load_today</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='
<span>1, 100, 99, 89, 95, 95, 92, 98, 100, 96, 97, 98, 99, 90, 85, 84</span></p><h4 id='262-电极合格率'><span>2.6.2 电极合格率</span></h4><p><span> </span><img src="snap/2-6-2.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_6_2_ele_qual_rate</span><span> </span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>date_1</span></td><td style='text-align:left;' ><span>第1天合格率</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>3</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>date_x</span></td><td style='text-align:left;' ><span>第x天合格率</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>3</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>date_15</span></td><td style='text-align:left;' ><span>第15天合格率</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>3</span></td><td style='text-align:left;' >&nbsp;</td></tr></tbody></table></figure><p><span>默认数据:</span>
<span>1, 100, 99, 89, 95, 95, 92, 98, 100, 96, 97, 98, 99, 90, 85, 84</span></p><h4 id='263-当天合格率'><span>2.6.3 当天合格率</span></h4><p><span> </span><img src="snap/2-6-3.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_6_3_qual_rate_today</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>qual_rate</span></td><td style='text-align:left;' ><span>合格率</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>3</span></td><td style='text-align:left;' >&nbsp;</td></tr></tbody></table></figure><p><span>默认数据90</span></p><h4 id='264-模具零件合格率'><span>2.6.4 模具零件合格率</span></h4><p><span> </span><img src="snap/2-6-4.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_6_4_mold_qual_rate</span><span> </span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>mold_name</span></td><td style='text-align:left;' ><span>模块名称</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>qual_rate</span></td><td style='text-align:left;' ><span>合格率</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>3</span></td><td style='text-align:left;' >&nbsp;</td></tr></tbody></table></figure><p><span>默认数据:</span></p><figure class='table-figure'><table><thead><tr><th><span>internal_id</span></th><th><span>mold_name</span></th><th><span>qual_rate</span></th></tr></thead><tbody><tr><td><span>1</span></td><td><span>IK19001</span></td><td><span>95</span></td></tr><tr><td><span>2</span></td><td><span>IK19002</span></td><td><span>88</span></td></tr><tr><td><span>3</span></td><td><span>IK19003</span></td><td><span>94</span></td></tr><tr><td><span>4</span></td><td><span>IK19004</span></td><td><span>75</span></td></tr><tr><td><span>5</span></td><td><span>IK19005</span></td><td><span>94</span></td></tr><tr><td><span>6</span></td><td><span>IK19006</span></td><td><span>89</span></td></tr></tbody></table></figure><h3 id='27-品质统计模块'><span>2.7 品质统计模块</span></h3><p><span> </span><img src="snap/2-7-0.jpg" referrerpolicy="no-referrer"></p><p><span>子模块表名对应表:</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>子模块标题</span></th><th style='text-align:left;' ><span>子模块表名</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>品质占比</span></td><td style='text-align:left;' ><span>t_7_1_qual_percent</span></td></tr><tr><td style='text-align:left;' ><span>班组合格率</span></td><td style='text-align:left;' ><span>t_7_2_group_qual_rate</span></td></tr><tr><td style='text-align:left;' ><span>每日合<EFBFBD><EFBFBD>
<span>1</span><span> </span><span>45</span><span> </span><span>30</span><span> </span><span>15</span><span> </span><span>10</span></p><h4 id='272-班组合格率'><span>2.7.2 班组合格率 </span></h4><p><span> </span><img src="snap/2-7-2.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_7_2_group_qual_rate</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>group_name</span></td><td style='text-align:left;' ><span>分组名称</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>qual_rate</span></td><td style='text-align:left;' ><span>合格率</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>3</span></td><td style='text-align:left;' >&nbsp;</td></tr></tbody></table></figure><p><span>默认数据:</span></p><figure class='table-figure'><table><thead><tr><th><span>internal_id</span></th><th><span>group_name</span></th><th><span>qual_rate</span></th></tr></thead><tbody><tr><td><span>1</span></td><td><span>CNC</span></td><td><span>90</span></td></tr><tr><td><span>2</span></td><td><span>EDM</span></td><td><span>85</span></td></tr><tr><td><span>3</span></td><td><span>WEDM</span></td><td><span>92</span></td></tr><tr><td><span>4</span></td><td><span>磨床</span></td><td><span>94</span></td></tr><tr><td><span>5</span></td><td><span>铣床</span></td><td><span>93</span></td></tr><tr><td><span>6</span></td><td><span>外协</span></td><td><span>92</span></td></tr></tbody></table></figure><h4 id='273-每日合格率统计'><span>2.7.3 每日合格率统计</span></h4><p><span> </span><img src="snap/2-7-3.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_7_3_qual_rate_daily</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>group_name</span></td><td style='text-align:left;' ><span>分组名称</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>day_1</span></td><td style='text-align:left;' ><span>第1天</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>3</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>day_x</span></td><td style='text-align:left;' ><span>第x天</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>3</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>day_31</span></td><td style='text-align:left;' ><span>第31天</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>3</span></t
<span>1, &#39;all&#39;, 90, 90, 97, 91, 92, 88, 89, 90, 78, 87, 86, 90, 80, 97, 87, 87, 88, 89, 90, 90, 89, 86, 90, 80, 97, 87, 87, 89, 89, 89, 90</span></p><h3 id='28-物料管理模块'><span>2.8 物料管理模块</span></h3><p><span> </span><img src="snap/2-8-0.jpg" referrerpolicy="no-referrer"></p><p><span>子模块表名对应表:</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>子模块标题</span></th><th style='text-align:left;' ><span>子模块表名</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>库存占比</span></td><td style='text-align:left;' ><span>t_8_1_key_invt</span></td></tr><tr><td style='text-align:left;' ><span>主要零件库存</span></td><td style='text-align:left;' ><span>t_8_2_invt_table</span></td></tr></tbody></table></figure><h4 id='281-库存占比'><span>2.8.1 库存占比</span></h4><p><span> </span><img src="snap/2-8-1.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_8_1_key_invt</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>name</span></td><td style='text-align:left;' ><span>名称</span></td><td style='text-align:left;' ><span>VARCHAR</span></td><td style='text-align:left;' ><span>255</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>upper_bound</span></td><td style='text-align:left;' ><span>上限</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' >&nbsp;</td></tr><tr><td style='text-align:left;' ><span>current</span></td><td style='text-align:left;' ><span>库存</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' >&nbsp;</td></tr></tbody></table></figure><p><span>默认数据:</span></p><figure class='table-figure'><table><thead><tr><th><span>internal_id</span></th><th><span>name</span></th><th><span>upper_bound</span></th><th><span>current</span></th></tr></thead><tbody><tr><td><span>1</span></td><td><span>刀具A1</span></td><td><span>200</span></td><td><span>110</span></td></tr><tr><td><span>2</span></td><td><span>顶针B</span></td><td><span>100</span></td><td><span>70</span></td></tr><tr><td><span>3</span></td><td><span>线割丝C</span></td><td><span>100</span></td><td><span>300</span></td></tr><tr><td><span>4</span></td><td><span>树脂D</span></td><td><span>100</span></td><td><span>10</span></td></tr></tbody></table></figure><h4 id='282-主要零件库存'><span>2.8.2 主要零件库存</span></h4><p><span> </span><img src="snap/2-8-2.jpg" referrerpolicy="no-referrer"></p><p><span>表名t_8_2_invt_table</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>字段名</span></th><th style='text-align:left;' ><span>中文名</span></th><th style='text-align:left;' ><span>类型</span></th><th style='text-align:left;' ><span>长度</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>internal_id</span></td><td style='text-align:left;' ><span>序号</span></td><td style='text-align:left;' ><span>INTEGER</span></td><td style='text-align:left;' ><span>11</span></td><td style='text-align:left;' ><span>主键自增</span></td></tr><tr><td style='text-align:left;' ><span>invt_no</span></td><td style='text-align:left;' ><span>编号</span
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">4</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-meta">#include "globalhead.h"</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">5</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-meta">#include "globalconfig.h"</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">6</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-meta">#include "qtabout.h"</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">7</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">8</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-keyword">class</span> <span class="cm-def">QtHelper</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">9</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">{</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">10</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-keyword">public</span>:</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">11</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取当前鼠标所在屏幕索引+尺寸</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">12</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">getScreenIndex</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">13</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QRect</span> <span class="cm-variable">getScreenRect</span>(<span class="cm-variable-3">bool</span> <span class="cm-variable">available</span> <span class="cm-operator">=</span> <span class="cm-atom">true</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">14</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
2022-06-02 06:34:10 +00:00
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">15</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取桌面宽度高度</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">16</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">deskWidth</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">17</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">deskHeight</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">18</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QSize</span> <span class="cm-variable">deskSize</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">19</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">20</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//居中显示窗体</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">21</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//定义标志位指定是以桌面为参照还是主程序界面为参照</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">22</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QWidget</span> <span class="cm-operator">*</span><span class="cm-variable">centerBaseForm</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">23</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setFormInCenter</span>(<span class="cm-variable">QWidget</span> <span class="cm-operator">*</span><span class="cm-variable">form</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">24</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">showForm</span>(<span class="cm-variable">QWidget</span> <span class="cm-operator">*</span><span class="cm-variable">form</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">25</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">26</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//程序文件名称及所在路径</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">27</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">appName</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">28</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">appPath</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">29</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">30</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取编译器字符串</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">31</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">getCompilerString</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">32</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取uuid</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">33</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">getUuid</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">34</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">35</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//新建目录</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">36</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">newDir</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">dirName</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">37</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//通用延时函数 支持Qt4 Qt5 Qt6</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">38</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">sleep</span>(<span class="cm-variable-3">int</span> <span class="cm-variable">msec</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">39</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">40</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置编码</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">41</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setCode</span>(<span class="cm-variable-3">bool</span> <span class="cm-variable">utf8</span> <span class="cm-operator">=</span> <span class="cm-atom">true</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">42</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置字体</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">43</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QFont</span> <span class="cm-variable">addFont</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">fontFile</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">fontName</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">44</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setFont</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">fontFile</span> <span class="cm-operator">=</span> <span class="cm-string">":/font/DroidSansFallback.ttf"</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">45</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">fontName</span> <span class="cm-operator">=</span> <span class="cm-variable">QUIConfig::FontName</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">46</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable-3">int</span> <span class="cm-variable">fontSize</span> <span class="cm-operator">=</span> <span class="cm-variable">QUICo
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">51</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//一次性设置所有包括编码字体翻译等</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">52</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">initAll</span>(<span class="cm-variable-3">bool</span> <span class="cm-variable">utf8</span> <span class="cm-operator">=</span> <span class="cm-atom">true</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">53</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//初始化main函数最前面执行的一段代码</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">54</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">initMain</span>(<span class="cm-variable-3">bool</span> <span class="cm-variable">on</span> <span class="cm-operator">=</span> <span class="cm-atom">true</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">55</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">56</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//16进制字符串转10进制</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">57</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">strHexToDecimal</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">strHex</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">58</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//10进制字符串转10进制</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">59</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">strDecimalToDecimal</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">strDecimal</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">60</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//2进制字符串转10进制</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">61</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">strBinToDecimal</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">strBin</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">62</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">63</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//16进制字符串转2进制字符串</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">64</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">strHexToStrBin</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">strHex</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">65</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//10进制转2进制字符串一个字节</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">66</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">decimalToStrBin1</span>(<span class="cm-variable-3">int</span> <span class="cm-variable">decimal</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">67</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//10进制转2进制字符串两个字节</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">68</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">decimalToStrBin2</span>(<span class="cm-variable-3">int</span> <span class="cm-variable">decimal</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">69</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//10进制转16进制字符串,补零.</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">70</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">decimalToStrHex</span>(<span class="cm-variable-3">int</span> <span class="cm-variable">decimal</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt"
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">72</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//int转字节数组</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">73</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QByteArray</span> <span class="cm-variable">intToByte</span>(<span class="cm-variable-3">int</span> <span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">74</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QByteArray</span> <span class="cm-variable">intToByteRec</span>(<span class="cm-variable-3">int</span> <span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">75</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">76</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//字节数组转int</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">77</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">byteToInt</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">78</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">byteToIntRec</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">79</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">quint32</span> <span class="cm-variable">byteToUInt</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">80</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">quint32</span> <span class="cm-variable">byteToUIntRec</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">81</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">82</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//ushort转字节数组</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">83</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QByteArray</span> <span class="cm-variable">ushortToByte</span>(<span class="cm-variable">ushort</span> <span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">84</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QByteArray</span> <span class="cm-variable">ushortToByteRec</span>(<span class="cm-variable">ushort</span> <span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">85</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">86</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//字节数组转ushort</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">87</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">byteToUShort</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">88</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">byteToUShortRec</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">89</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">90</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//字符串补全</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">91</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">getValue</span>(<span class="cm-variable">quint8</span> <span class="cm-variable">value</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">92</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//字符串去空格 -1=移除左侧空格 0=移除所有空格 1=移除右侧空格 2=移除首尾空格 3=首尾清除中间留一个空格</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">93</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">trimmed</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">text</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">type</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">94</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">95</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//异或加密-只支持字符,如果是中文需要将其转换base64编码</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">96</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">getXorEncryptDecrypt</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">value</span>, <span class="cm-variable-3">char</span> <span class="cm-variable">key</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">97</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//异或校验</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">98</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">uchar</span> <span class="cm-variable">getOrCode</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">99</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//计算校验码</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">100</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">uchar</span> <span class="cm-variable">getCheckCode</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">101</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">102</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//CRC校验</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">103</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QByteArray</span> <span class="cm-variable">getCrcCode</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">104</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">105</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//字节数组与Ascii字符串互转</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">106</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">byteArrayToAsciiStr</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">107</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QByteArray</span> <span class="cm-variable">asciiStrToByteArray</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">108</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">109</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//16进制字符串与字节数组互转</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">110</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QByteArray</span> <span class="cm-variable">hexStrToByteArray</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">111</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">byteArrayToHexStr</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QByteArray</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">112</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">113</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//选择文件对话框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">114</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">getOpenFileName</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">filter</span> <span class="cm-operator">=</span> <span class="cm-variable">QString</span>(),</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">115</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">dirName</span> <span class="cm-operator">=</span> <span class="cm-variable">QString</span>(),</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">116</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">fileName</span> <span class="cm-operator">=</span> <span class="cm-variable">QString</span>(),</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">117</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-variable-3">bool</span> <span class="cm-variable">native</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">width</span> <span class="cm-operator">=</span> <span class="cm-number">900</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">height</span> <span class="cm-operator">=</span> <span class="cm-number">600</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">118</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//保存文件对话框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">119</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="c
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">127</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取文件名,含拓展名</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">128</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">getFileNameWithExtension</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">fileName</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">129</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取选择文件夹中的文件</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">130</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QStringList</span> <span class="cm-variable">getFolderFileNames</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QStringList</span> <span class="cm-operator">&amp;</span><span class="cm-variable">filter</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">131</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">132</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//复制文件</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">133</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">bool</span> <span class="cm-variable">copyFile</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">sourceFile</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">targetFile</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">134</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//删除文件夹下所有文件</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">135</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">deleteDirectory</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">path</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">136</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">137</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//从字符串获取IP地址</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">138</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">getIP</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">url</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">139</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//判断是否是IP地址</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">140</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">bool</span> <span class="cm-variable">isIP</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">ip</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">141</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//判断是否是MAC地址</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">142</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">bool</span> <span class="cm-variable">isMac</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">mac</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">143</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//判断是否是合法的电话号码</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">144</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">bool</span> <span class="cm-variable">isTel</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">tel</span>);</span></pre></div><div style
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">148</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//IP地址字符串与整型转换</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">149</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">ipv4IntToString</span>(<span class="cm-variable">quint32</span> <span class="cm-variable">ip</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">150</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">quint32</span> <span class="cm-variable">ipv4StringToInt</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">ip</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">151</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">152</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//判断IP地址及端口是否在线</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">153</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">bool</span> <span class="cm-variable">ipLive</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">ip</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">port</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">1000</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">154</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//下载网络文件</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">155</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">bool</span> <span class="cm-variable">download</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">url</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">fileName</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">1000</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">156</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取网页所有源代码</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">157</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QByteArray</span> <span class="cm-variable">getHtml</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">url</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">1000</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">158</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">159</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取本机公网IP地址</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">160</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">getNetIP</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">html</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">161</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取本机IP</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">162</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">getLocalIP</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">163</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取本机IP地址集合</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">164</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QStringList</span> <span class="cm-variable">getLocalIPs</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">165</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//Url地址转为IP地址</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">166</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">urlToIP</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">url</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">167</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">168</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置边框阴影</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">169</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setFormShadow</span>(<span class="cm-variable">QWidget</span> <span class="cm-operator">*</span><span class="cm-variable">widget</span>, <span class="cm-variable">QLayout</span> <span class="cm-operator">*</span><span class="cm-variable">layout</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">color</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">margin</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">radius</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">170</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//立即更新所有阴影边框颜色比如换肤的时候需要用到</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">171</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setFormShadow</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">color</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">172</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">173</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置无边框窗体</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">174</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setFramelessForm</span>(<span class="cm-variable">QWidget</span> <span class="cm-operator">*</span><span class="cm-variable">widgetMain</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">175</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-variable-3">bool</span> <span class="cm-variable">tool</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">top</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">176</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-variable-3">bool</span> <span class="cm-variable">menu</span> <span class="cm-operator">=</span> <span class="cm-atom">true</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">x11</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">177</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setFramelessForm</span>(<span class="cm-variable">QWidget</span> <span class="cm-operator">*</span><span class="cm-variable">widgetMain</span>, <span class="cm-variable">QWidget</span> <span class="cm-operator">*</span><span class="cm-variable">widgetTitle</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">178</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-variable">QLabel</span> <span class="cm-operator">*</span><span class="cm-variable">labIco</span>, <span class="cm-variable">QPushButton</span> <span class="cm-operator">*</span><span class="cm-variable">btnClose</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">179</div></div><pre class=" CodeMirror-line " role="presentation"><s
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">182</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//通用弹出框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">183</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">showMessageBox</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">info</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">type</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">exec</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">184</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//弹出消息框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">185</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">showMessageBoxInfo</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">info</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">exec</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">186</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//弹出错误框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">187</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">showMessageBoxError</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">info</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">exec</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><di
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">191</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//弹出右下角信息框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">192</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">showTipBox</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">title</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">tip</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">fullScreen</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">193</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-variable-3">bool</span> <span class="cm-variable">center</span> <span class="cm-operator">=</span> <span class="cm-atom">true</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">194</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//隐藏右下角信息框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">195</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">hideTipBox</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">196</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">197</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//弹出输入框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">198</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">showInputBox</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">title</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">type</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">199</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">placeholderText</span> <span class="cm-operator">=</span> <span class="cm-variable">QString</span>(), <span class="cm-variable-3">bool</span> <span class="cm-variable">pwd</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">200</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">defaultValue</span> <span class="cm-operator">=</span> <span class="cm-variable">QString</span>());</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">201</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//弹出日期选择框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">202</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">int</span> <span class="cm-variable">showDateSelect</span>(<span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">dateStart</span>, <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">dateEnd</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">format</span> <
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">204</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//弹出关于对话框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">205</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">showAboutInfo</span>(<span class="cm-keyword">const</span> <span class="cm-variable">AboutInfo</span> <span class="cm-operator">&amp;</span><span class="cm-variable">info</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">exec</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">206</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//弹出中间提示框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">207</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">showSplashInfo</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">info</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">fontSizeMain</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">fontSizeSub</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">timeout</span> <span class="cm-operator">=</span> <span class="cm-number">0</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">exec</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">208</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//隐藏中间提示框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">209</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">hideSplashInfo</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">210</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">211</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取等比例缩放过的图片</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">212</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QPixmap</span> <span class="cm-variable">getPixmap</span>(<span class="cm-variable">QWidget</span> <span class="cm-operator">*</span><span class="cm-variable">widget</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QPixmap</span> <span class="cm-operator">&amp;</span><span class="cm-variable">pixmap</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">scale</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">213</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setPixmap</span>(<span class="cm-variable">QLabel</span> <span class="cm-operator">*</span><span class="cm-variable">label</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">file</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">scale</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">214</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置logo图片支持 资源文件+本地图片+图形字体+svg自动变色 等多种形式</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">215</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setLogo</span>(<span class="cm-variable">QLabel</span> <span class="cm-operator">*</span><span class="cm-variable">label</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">file</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">216</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable-3">int</span> <span class="cm-variable">width</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">height</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">offset</span> <span class="cm-operator">=</span> <span class="cm-number">20</span>,</span></pre></di
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">219</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//初始化数据库</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">220</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">initDb</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">dbName</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">221</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//初始化文件,不存在则拷贝</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">222</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">initFile</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">sourceName</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">targetName</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">223</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//检查ini配置文件</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">224</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">bool</span> <span class="cm-variable">checkIniFile</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">iniFile</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">225</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">226</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置图标到按钮</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">227</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setIconBtn</span>(<span class="cm-variable">QAbstractButton</span> <span class="cm-operator">*</span><span class="cm-variable">btn</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">png</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">icon</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">228</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">229</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//写入消息到额外的的消息日志文件</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">230</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">writeInfo</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">info</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">needWrite</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">filePath</span> <span class="cm-operator">=</span> <span class="cm-string">"log"</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">231</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">writeError</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">info</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">needWrite</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">filePath</span> <span class="cm-operator">=</span> <span class="cm-string">"log"</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">232</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">233</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置系统时间</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">234</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">setSystemDateTime</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">year</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">month</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">day</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">235</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">hour</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">min</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">sec</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">236</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置开机自启动</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">237</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">runWithSystem</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">name</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">path</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">autoRun</span> <span class="cm-operator">=</span> <span class="cm-atom">true</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">238</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">239</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取内置颜色集合</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">240</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QList</span><span class="cm-operator">&lt;</span><span class="cm-variable">QColor</span><span class="cm-operator">&gt;</span> <span class="cm-variable">getColorList</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">241</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QStringList</span> <span class="cm-variable">getColorNames</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">242</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//随机获取颜色集合中的颜色</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">243</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QColor</span> <span class="cm-variable">getRandColor</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">244</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">245</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//初始化随机数种子</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">246</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">initRand</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">247</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取随机小数</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">248</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">float</span> <span class="cm-variable">getRandFloat</span>(<span class="cm-variable-3">float</span> <span class="cm-variable">min</span>, <span class="cm-variable-3">float</span> <span class="cm-variable">max</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">249</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取随机数,指定最小值和最大值</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">250</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">double</span> <span class="cm-variable">getRandValue</span>(<span class="cm-variable-3">int</span> <span class="cm-variable">min</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">max</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">contansMin</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">contansMax</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">251</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//获取范围值随机经纬度集合</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">252</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QStringList</span> <span class="cm-variable">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">254</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//初始化表格</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">255</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">initTableView</span>(<span class="cm-variable">QTableView</span> <span class="cm-operator">*</span><span class="cm-variable">tableView</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">rowHeight</span> <span class="cm-operator">=</span> <span class="cm-number">25</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">256</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable-3">bool</span> <span class="cm-variable">headVisible</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">edit</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">257</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable-3">bool</span> <span class="cm-variable">stretchLast</span> <span class="cm-operator">=</span> <span class="cm-atom">true</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">258</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//打开文件带提示框</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">259</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable-3">void</span> <span class="cm-variable">openFile</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">fileName</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">msg</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">260</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//导出和打印数据提示框</span></span></pre></div><div style="position: relative;"><di
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">263</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//插入消息</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">264</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">appendMsg</span>(<span class="cm-variable">QTextEdit</span> <span class="cm-operator">*</span><span class="cm-variable">textEdit</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">type</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">265</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-variable-3">int</span> <span class="cm-variable">maxCount</span>, <span class="cm-variable-3">int</span> <span class="cm-operator">&amp;</span><span class="cm-variable">currentCount</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">266</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-variable-3">bool</span> <span class="cm-variable">clear</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>, <span class="cm-variable-3">bool</span> <span class="cm-variable">pause</span> <span class="cm-operator">=</span> <span class="cm-atom">false</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">267</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//首尾截断字符串显示</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 36px;">268</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QString</span> <span class="cm-variable">cutString</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">text</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">len</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">left</span>, <span class="cm-variable-3">int</span> <span class="cm-variable">right</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">mid</span> <span class="cm-operator">=</span> <span class="cm-string">"..."</span>);</span></pre></div><div style="position: relative;"><div class="Code
2023-12-25 05:50:42 +00:00
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -45px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 36px;">271</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-meta">#endif </span><span class="cm-comment">// QTHELPER_H</span></span></pre></div></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 6404px;"></div><div class="CodeMirror-gutters" style="height: 6404px;"><div class="CodeMirror-gutter CodeMirror-linenumbers" style="width: 44px;"></div></div></div></div></pre><h4 id='443-初始化及辅助'><span>4.4.3 初始化及辅助</span></h4><p><span> </span><img src="snap/4-4-3.jpg" referrerpolicy="no-referrer"></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>名称</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>appconfig</span></td><td style='text-align:left;' ><span>配置参数类整个系统的配置参数存放在ini文件中跨平台所有参数都对应一个变量读取配置参数的时候将值赋值给变量写入的时候将变量值写入到配置文件。</span></td></tr><tr><td style='text-align:left;' ><span>appfun</span></td><td style='text-align:left;' ><span>辅助函数类,比如重启,获取随机数、从多个数组中取出最大值等。</span></td></tr><tr><td style='text-align:left;' ><span>appinit</span></td><td style='text-align:left;' ><span>程序初始化类在main函数中会先执行这个初始化的类比如初始化皮肤、字体、数据库、样式等操作这些都是要优先在窗体加载前执行的执行完毕以后再打开窗体主界面。</span></td></tr><tr><td style='text-align:left;' ><span>appkey</span></td><td style='text-align:left;' ><span>通用秘钥管理类。</span></td></tr></tbody></table></figure><h4 id='444-自定义控件'><span>4.4.4 自定义控件</span></h4><p><span> </span><img src="snap/4-4-4.jpg" referrerpolicy="no-referrer"></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>名称</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>customchart</span></td><td style='text-align:left;' ><span>自定义图表控件</span></td></tr><tr><td style='text-align:left;' ><span>custompie</span></td><td style='text-align:left;' ><span>自定义饼状图纯painter绘制弥补qchart组件不支持qt4等版本。</span></td></tr><tr><td style='text-align:left;' ><span>customtitlebar</span></td><td style='text-align:left;' ><span>自定义模块标题栏</span></td></tr><tr><td style='text-align:left;' ><span>gaugepercent</span></td><td style='text-align:left;' ><span>百分比仪表盘</span></td></tr><tr><td style='text-align:left;' ><span>gaugespeed</span></td><td style='text-align:left;' ><span>速度仪表盘</span></td></tr><tr><td style='text-align:left;' ><span>progressring</span></td><td style='text-align:left;' ><span>环形进度条</span></td></tr><tr><td style='text-align:left;' ><span>progressthree</span></td><td style='text-align:left;' ><span>三态进度条</span></td></tr><tr><td style='text-align:left;' ><span>switchbutton</span></td><td style='text-align:left;' ><span>开关按钮</span></td></tr></tbody></table></figure><p><span> </span><img src="snap/4-4-4-1.jpg" referrerpolicy="no-referrer"><span> </span>
2022-06-02 06:34:10 +00:00
<span> </span><img src="snap/4-4-4-2.jpg" referrerpolicy="no-referrer"><span> </span>
<span> </span><img src="snap/4-4-4-3.jpg" referrerpolicy="no-referrer"><span> </span>
<span> </span><img src="snap/4-4-4-4.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/4-4-4-5.jpg" referrerpolicy="no-referrer"><span> </span>
<span> </span><img src="snap/4-4-4-6.jpg" referrerpolicy="no-referrer"><span> </span>
<span> </span><img src="snap/4-4-4-7.jpg" referrerpolicy="no-referrer">
2023-12-25 05:50:42 +00:00
<span> </span><img src="snap/4-4-4-8.jpg" referrerpolicy="no-referrer"><span> </span></p><h3 id='45-内核模块'><span>4.5 内核模块</span></h3><h4 id='451-通用自定义控件'><span>4.5.1 通用自定义控件</span></h4><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>名称</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>bottomwidget</span></td><td style='text-align:left;' ><span>通用底部状态栏控件,可以设置软件名称、版本号、运行时间等。</span></td></tr><tr><td style='text-align:left;' ><span>colorcombobox</span></td><td style='text-align:left;' ><span>颜色下拉框控件,在系统设置中有。</span></td></tr><tr><td style='text-align:left;' ><span>cpumemorylabel</span></td><td style='text-align:left;' ><span>CPU和内存使用情况标签控件主界面右上角显示。</span></td></tr><tr><td style='text-align:left;' ><span>customtitlebar</span></td><td style='text-align:left;' ><span>停靠窗体自定义标题栏控件。</span></td></tr><tr><td style='text-align:left;' ><span>devicebutton</span></td><td style='text-align:left;' ><span>设备按钮控件,比如图片地图模块中用到,可设置不同的图标样式和状态等,双击发出信号进行相应处理比如弹出对应视频预览等。</span></td></tr><tr><td style='text-align:left;' ><span>framelesswidget</span></td><td style='text-align:left;' ><span>无边框窗体管理类,无边框拖动+拉伸,主界面就用到了这个类。</span></td></tr><tr><td style='text-align:left;' ><span>lcddatetime</span></td><td style='text-align:left;' ><span>软件右上角显示时间的控件。</span></td></tr><tr><td style='text-align:left;' ><span>panelwidget</span></td><td style='text-align:left;' ><span>面板容器控件主界面子模块表格消息就用到此控件用于将一堆widget放到此容器进行管理自动形成滚动条等。</span></td></tr><tr><td style='text-align:left;' ><span>switchbutton</span></td><td style='text-align:left;' ><span>开关按钮控件,在系统设置中存在大量该控件。</span></td></tr><tr><td style='text-align:left;' ><span>xslider</span></td><td style='text-align:left;' ><span>滑动条控件,在原有滑动条基础上增加了鼠标按下立即定位等。</span></td></tr></tbody></table></figure><h4 id='452-图表组件内核'><span>4.5.2 图表组件内核</span></h4><p><span> </span><img src="snap/4-5-2.jpg" referrerpolicy="no-referrer"></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>名称</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>customplot</span></td><td style='text-align:left;' ><span>自定义图表组件类。</span></td></tr><tr><td style='text-align:left;' ><span>customplotbarh</span></td><td style='text-align:left;' ><span>自定义形状-横向柱状图。</span></td></tr><tr><td style='text-align:left;' ><span>customplotbarv</span></td><td style='text-align:left;' ><span>自定义形状-垂直柱状图。</span></td></tr><tr><td style='text-align:left;' ><span>customplothead</span></td><td style='text-align:left;' ><span>当前组件通用头文件。</span></td></tr><tr><td style='text-align:left;' ><span>customplothelper</span></td><td style='text-align:left;' ><span>当前组件通用辅助函数文件。</span></td></tr><tr><td style='text-align:left;' ><span>customplotline</span></td><td style='text-align:left;' ><span>自定义形状-平滑曲线图。</span></td></tr><tr><td style='text-align:left;' ><span>customplottracer</span></td><td style='text-align:left;' ><span>自定义图层绘制十字线,也叫游标,定位线。</span></td></tr><tr><td style='text-align:left;' ><span>smoothcurve</span></td><td style='text-align:left;' ><span>平滑曲线算法类,内置多种平滑算法,可以自行增加其他算法。</span></td></tr></tbody></table></figure><h4 id='453-数<><E695B0>
2022-06-02 06:34:10 +00:00
<span>dbconnthread封装的一个通用的数据库通信类支持sqlite、mysql、PostgreSQL等数据库功能包括了数据库的打开和关闭线程执行sql语句队列信号发出执行结果等支持重连。</span>
2023-12-25 05:50:42 +00:00
<span>dbhttpthread本系统除了支持数据库采集模式以外还支持发送http网络请求的方式来采集数据请求中带对应要查询的表字段等信息这个类就是专门的请求类请求结果自动过滤运算并信号发出去返回数据的信号和数据库采集的信号完全一致使得主界面关联到同一个槽函数就能正常工作。</span></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>名称</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>dbcleanthread</span></td><td style='text-align:left;' ><span>自动清理数据线程类。</span></td></tr><tr><td style='text-align:left;' ><span>dbconnthread</span></td><td style='text-align:left;' ><span>数据库通信管理线程类。</span></td></tr><tr><td style='text-align:left;' ><span>dbdelegate</span></td><td style='text-align:left;' ><span>自定义委托全家桶,包括复选框、下拉框、密码框、按钮等。</span></td></tr><tr><td style='text-align:left;' ><span>dbhead</span></td><td style='text-align:left;' ><span>当前组件通用头文件。</span></td></tr><tr><td style='text-align:left;' ><span>dbhelper</span></td><td style='text-align:left;' ><span>各种数据库应用函数封装比如初始化数据库、执行sql语句等。</span></td></tr><tr><td style='text-align:left;' ><span>dbhttpthread</span></td><td style='text-align:left;' ><span>网络请求数据采集类。</span></td></tr><tr><td style='text-align:left;' ><span>dbpage</span></td><td style='text-align:left;' ><span>数据库通用翻页类。</span></td></tr><tr><td style='text-align:left;' ><span>dbpagemodel</span></td><td style='text-align:left;' ><span>数据库翻页类数据模型。</span></td></tr><tr><td style='text-align:left;' ><span>navpage</span></td><td style='text-align:left;' ><span>分页导航控件。</span></td></tr></tbody></table></figure><h4 id='454-大屏地图内核'><span>4.5.4 大屏地图内核</span></h4><p><span> </span><img src="snap/4-5-4.jpg" referrerpolicy="no-referrer"></p><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>名称</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>echartjs</span></td><td style='text-align:left;' ><span>echart模块中用到的json文件转js文件获取js文件中的名字和经纬度等处理。</span></td></tr><tr><td style='text-align:left;' ><span>echarts</span></td><td style='text-align:left;' ><span>echart封装类可加载仪表盘、闪烁点图、迁徙图、世界地图、区域地图等每个点可自定义颜色和提示信息等。</span></td></tr><tr><td style='text-align:left;' ><span>mapbaidu</span></td><td style='text-align:left;' ><span>百度地图封装类,支持在线和离线两种模式。</span></td></tr></tbody></table></figure><h4 id='455-视频监控内核'><span>4.5.5 视频监控内核</span></h4><p><span> </span><img src="snap/4-5-5.jpg" referrerpolicy="no-referrer">
<span>视频组件继承和依赖关系说明:</span></p><ol start='' ><li><p><span>videobase是基类组件video是视频播放组件依赖基类组件videoffmpeg是具体的内核实现组件依赖视频播放组件。</span></p></li><li><p><span>video组件中的videothread解码线程类继承自videobase基类组件中的abstractvideothread。</span></p></li><li><p><span>video组件中的videowidgetx视频显示类继承自videobase基类组件中的abstractvideowidget。</span></p></li><li><p><span>videoffmpeg组件中的ffmpegthread继承自video组件中的videothread。</span></p></li><li><p><span>videoffmpeg组件中的ffmpegsave继承自videobase组件中的abstractsavethread。</span></p></li><li><p><span>按照此规则还有其他内核比如vlc组件中的vlcthread也是继承自videothreadmpv组件中的mpvthread也是继承自videothread。这样新增一种内核只要具体实现部分处理函数即可应用整个视频框架。</span></p></li><li><p><span>通过多层基类继承关系,使得动态挂载任意解码内核极为方便。</span></p></li><li><p><span>为何在video视频组件的基础上还要提炼一个videobase基类组件因为该基类组件还可以提供给camera本地摄像头采集组件使用基类中的变量、函数、处理逻辑几乎一致但是又有特殊性所以需要分开再提炼出videobase基类。</span></p></li></ol><h5 id='4551-视频播放组件'><span>4.5.5.1 视频播放组件</span></h5><figure class='table-figure'><table><thead><tr><th style='text-align:left;' ><span>名称</span></th><th style='text-align:left;' ><span>说明</span></th></tr></thead><tbody><tr><td style='text-align:left;' ><span>videobox</span></td><td style='text-align:left;' ><span>监控画面切换控件,将所有通道切换处理全部集中到一个类,通用异形布局切换函数,可以参考进行自定义异形布局,通道布局切换发出信号通知,支持自定义子菜单布局内容。</span></td></tr><tr><td style='text-align:left;' ><span>videohelper</span></td><td style='text-align:left;' ><span>视频相关辅助函数比如根据url地址取出ip地址、校验网络地址是否可达、检查地址是否正常、根据地址获取本地摄像头参数、获取本地桌面采集参数、创建视频采集类、对采集线程设置参数等。</span></td></tr><tr><td style='text-align:left;' ><span>videoutil</span></td><td style='text-align:left;' ><span>视频相关辅助函数,加载视频内核、视频地址、视频模式、解码策略、编码策略、硬件加速、通信协议、缓存时间、读取超时等。</span></td></tr><tr><td style='text-align:left;' ><span>videomanage</span></td><td style='text-align:left;' ><span>视频线程管理类,全局单例,将所有视频控件发给此类管理,负责挨个打开视频、应用录像计划等。</span></td></tr><tr><td style='text-align:left;' ><span>videoplayback</span></td><td style='text-align:left;' ><span>视频回放控件,支持多个通道,显示每个通道对应的视频段。</span></td></tr><tr><td style='text-align:left;' ><span>videostruct</span></td><td style='text-align:left;' ><span>视频播放组件结构体定义类,包括解析内核枚举值、视频类型枚举值、解码策略枚举值、视频采集参数结构体。</span></td></tr><tr><td style='text-align:left;' ><span>videotask</span></td><td style='text-align:left;' ><span>视频任务线程类全局单例可以随时插入一些视频相关的任务进行处理比如vlc录制视频后需要重命名文件mpv内核关闭视频后鼠标指针打圈圈需要复位。</span></td></tr><tr><td style='text-align:left;' ><span>videothread</span></td><td style='text-align:left;' ><span>视频解码线程类,内置了共享解码线程处理逻辑,可以打开视频、关闭视频、设置视频宽高比例、获取文件总时长、获取媒体信息、获取和设置播放位置、获取和设置播放速度、获取和设置音量大小、获取和设
2022-06-02 06:34:10 +00:00
2023-12-25 05:50:42 +00:00
<script>(function(){function e(e,n,i){document.addEventListener(e,function(e){if(!e.defaultPrevented)for(var t=e.target;t&&t!=this;t=t.parentNode)if(t.matches(n)){!1===i.call(t,e)&&(e.preventDefault(),e.stopPropagation());break}},!1)}var t=document.body.parentElement,i=[],r=null,o=document.body.classList.contains("typora-export-collapse-outline");function a(){return t.scrollTop}e("click",".outline-expander",function(e){var t=this.closest(".outline-item-wrapper").classList;return t.contains("outline-item-open")?t.remove("outline-item-open"):t.add("outline-item-open"),u(),!1}),e("click",".outline-item",function(e){var t=this.querySelector(".outline-label");location.hash="#"+t.getAttribute("href"),o&&((t=this.closest(".outline-item-wrapper").classList).contains("outline-item-open")||t.add("outline-item-open"),d(),t.add("outline-item-active"))});function s(){var e=a();r=null;for(var t=0;t<i.length&&i[t][1]-e<60;t++)r=i[t]}function n(){c=setTimeout(function(){var n;i=[],n=a(),document.querySelector("#write").querySelectorAll("h1, h2, h3, h4, h5, h6").forEach(e=>{var t=e.getAttribute("id");i.push([t,n+e.getBoundingClientRect().y])}),s(),u()},300)}var l,c,d=function(){document.querySelectorAll(".outline-item-active").forEach(e=>e.classList.remove("outline-item-active")),document.querySelectorAll(".outline-item-single.outline-item-open").forEach(e=>e.classList.remove("outline-item-open"))},u=function(){if(r&&(d(),t=document.querySelector('.outline-label[href="#'+(CSS.escape?CSS.escape(r[0]):r[0])+'"]')))if(o){var e=t.closest(".outline-item-open>ul>.outline-item-wrapper");if(e)e.classList.add("outline-item-active");else{for(var t,n=(t=t.closest(".outline-item-wrapper")).parentElement.closest(".outline-item-wrapper");n;)n=(t=n).parentElement.closest(".outline-item-wrapper");t.classList.add("outline-item-active")}}else t.closest(".outline-item-wrapper").classList.add("outline-item-active")};window.addEventListener("scroll",function(e){l&&clearTimeout(l),l=setTimeout(function(){s(),u()},300)});window.addEventListener("resize",function(e){c&&clearTimeout(c),n()}),n()})();</script></body>
2021-07-10 09:34:53 +00:00
</html>