<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                企業??AI智能體構建引擎,智能編排和調試,一鍵部署,支持知識庫和私有化部署方案 廣告
                [TOC] > [therecipe/qt](https://github.com/therecipe/qt) > [examples](https://github.com/therecipe/examples) ## 安裝教程 > [官方參考](https://github.com/therecipe/qt/wiki/Installation-on-Windows) ``` md go-qt && cd go-qt set GO111MODULE=on go mod init go-qt go get -v github.com/therecipe/qt go install -v -tags=no_env github.com/therecipe/qt/cmd/... //把之前下載的 therecipe/qt 轉移到 vendor目錄 go mod vendor // 在已有vendor時,進行 git clone,放置原來的vendor 被覆蓋 git clone https://github.com.cnpmjs.org/therecipe/env_windows_amd64_513.git vendor/github.com/therecipe/env_windows_amd64_513 //注意最后輸出的異常,并解決之 for /f %v in ('go env GOPATH') do %v\bin\qtsetup ``` ### 正式版(具有WebEngine / WebView支持) [參考](https://github.com/therecipe/qt/wiki/Installation-on-Windows#official-version-with-webenginewebview-support) ## 教程 1. 創建應用的方式可以通過 QML配置文件,也可以直接使用go代碼,可通過 [base項目](https://github.com/therecipe/examples/tree/master/basic) 在個項目查看 2. 可支持交叉編譯 ## 常用命令 ``` qtdeploy test desktop <含main.go目錄> 直接運行 qtdeploy build desktop <含main.go目錄> 編 ``` ## 實例 ### 自定義實例1 ``` md demo1 && cd demo1 //創建 main.go ``` <details> <summary>main.go</summary> ``` package main import ( "os" "github.com/therecipe/qt/widgets" ) func main() { // needs to be called once before you can start using the QWidgets app := widgets.NewQApplication(len(os.Args), os.Args) // create a window // with a minimum size of 250*200 // and sets the title to "Hello Widgets Example" window := widgets.NewQMainWindow(nil, 0) window.SetMinimumSize2(250, 200) window.SetWindowTitle("Hello Widgets Example") // create a regular widget // give it a QVBoxLayout // and make it the central widget of the window widget := widgets.NewQWidget(nil, 0) widget.SetLayout(widgets.NewQVBoxLayout()) window.SetCentralWidget(widget) // create a line edit // with a custom placeholder text // and add it to the central widgets layout input := widgets.NewQLineEdit(nil) input.SetPlaceholderText("Write something ...") widget.Layout().AddWidget(input) // create a button // connect the clicked signal // and add it to the central widgets layout button := widgets.NewQPushButton2("and click me!", nil) button.ConnectClicked(func(bool) { widgets.QMessageBox_Information(nil, "OK", input.Text(), widgets.QMessageBox__Ok, widgets.QMessageBox__Ok) }) widget.Layout().AddWidget(button) // make the window visible window.Show() // start the main Qt event loop // and block until app.Exit() is called // or the window is closed by the user app.Exec() } ``` </details> <br/> 運行 `qtdeploy test desktop demo1` ### 官方實例 > [examples](https://github.com/therecipe/examples) 注意如果報錯,需要刪除 examples 中的go.mod 文件,
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看