为什么执行Python QT5代码时未显示图标和图像?

高蒂尔·布特兹(Gauthier Buttez)

环境:

的Python 3.7.7

Qt5

Qt Designer 5.11

问题:

我使用Qt Designer设计了一个GUI,并在标签和按钮中的图标背景中添加了一些图像。我可以从软件Qt设计器中正确看到图像和图标。但是,当我执行python脚本来加载UI时,我再也看不到图像了。

码:

我在根文件夹上有我的主要python脚本,在“ ui”文件夹中有ui,qrc和图像文件:

main.py
ui/config.qrc
ui/doc.qrc
ui/document.png
ui/gear.png
ui/logo.qrc
ui/logo_MyUI_300.jpg
ui/MyUI.ui
ui/play-button.png
ui/play.png
ui/question.png
ui/quit.png
ui/quit.qrc
ui/report.qrc
ui/run.qrc
ui/save.png
ui/save.qrc
ui/scan.qrc
ui/search.png
ui/seo-report.png
ui/support.qrc
ui/telegram.png
ui/telegram.qrc
ui/watch_videos.qrc

main.py:

from PyQt5 import QtWidgets, uic

gui = QtWidgets.QApplication([])
ui=uic.loadUi('ui/MyUI.ui')

ui.show()
gui.exec()

MyUI.ui:

<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
 <author>MyUI.co</author>
 <class>MainWindow</class>
 <widget class="QMainWindow" name="MainWindow">
  <property name="geometry">
   <rect>
    <x>0</x>
    <y>0</y>
    <width>800</width>
    <height>580</height>
   </rect>
  </property>
  <property name="windowTitle">
   <string>MyUI.co</string>
  </property>
  <property name="windowIcon">
   <iconset>
    <normalon>:/logo/logo_MyUI_300.jpg</normalon>
   </iconset>
  </property>
  <property name="styleSheet">
   <string notr="true">background-color: rgb(255, 255, 255);</string>
  </property>
  <widget class="QWidget" name="centralwidget">
   <widget class="QLineEdit" name="lineEdit_Email">
    <property name="geometry">
     <rect>
      <x>126</x>
      <y>190</y>
      <width>221</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="placeholderText">
     <string>i.e: [email protected]</string>
    </property>
   </widget>
   <widget class="QLineEdit" name="lineEdit_License">
    <property name="geometry">
     <rect>
      <x>126</x>
      <y>220</y>
      <width>221</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="placeholderText">
     <string>i.e: gold89DE-B4JI-HQ3E-D8UT</string>
    </property>
   </widget>
   <widget class="QLabel" name="label">
    <property name="geometry">
     <rect>
      <x>76</x>
      <y>190</y>
      <width>41</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Email</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_2">
    <property name="geometry">
     <rect>
      <x>10</x>
      <y>10</y>
      <width>75</width>
      <height>75</height>
     </rect>
    </property>
    <property name="autoFillBackground">
     <bool>true</bool>
    </property>
    <property name="styleSheet">
     <string notr="true">background-image: url(:/logo/logo_MyUI_300.jpg);</string>
    </property>
    <property name="text">
     <string/>
    </property>
    <property name="textFormat">
     <enum>Qt::RichText</enum>
    </property>
    <property name="pixmap">
     <pixmap resource="logo.qrc">:/logo/logo_MyUI_300.jpg</pixmap>
    </property>
    <property name="openExternalLinks">
     <bool>false</bool>
    </property>
   </widget>
   <widget class="QLabel" name="label_3">
    <property name="geometry">
     <rect>
      <x>36</x>
      <y>220</y>
      <width>81</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>License Key</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_1">
    <property name="geometry">
     <rect>
      <x>36</x>
      <y>140</y>
      <width>31</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>20</pointsize>
     </font>
    </property>
    <property name="text">
     <string>1.</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_1_Title">
    <property name="geometry">
     <rect>
      <x>66</x>
      <y>146</y>
      <width>231</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>16</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Activate your MyUI</string>
    </property>
   </widget>
   <widget class="QPushButton" name="button_SaveLicense">
    <property name="geometry">
     <rect>
      <x>256</x>
      <y>260</y>
      <width>91</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>16</pointsize>
     </font>
    </property>
    <property name="styleSheet">
     <string notr="true">background-color: rgb(199, 199 199);</string>
    </property>
    <property name="text">
     <string>Save</string>
    </property>
    <property name="icon">
     <iconset>
      <normalon>:/save/save.png</normalon>
     </iconset>
    </property>
   </widget>
   <widget class="QLabel" name="label_5">
    <property name="geometry">
     <rect>
      <x>36</x>
      <y>304</y>
      <width>31</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>20</pointsize>
     </font>
    </property>
    <property name="text">
     <string>2.</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_2_Title">
    <property name="geometry">
     <rect>
      <x>66</x>
      <y>310</y>
      <width>331</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>16</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Required Softwares are Installed?</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_8">
    <property name="geometry">
     <rect>
      <x>86</x>
      <y>350</y>
      <width>101</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Java Runtime:</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_9">
    <property name="geometry">
     <rect>
      <x>186</x>
      <y>350</y>
      <width>41</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>No</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_10">
    <property name="geometry">
     <rect>
      <x>186</x>
      <y>370</y>
      <width>41</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>No</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_11">
    <property name="geometry">
     <rect>
      <x>126</x>
      <y>370</y>
      <width>61</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>NodeJS:</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_12">
    <property name="geometry">
     <rect>
      <x>186</x>
      <y>390</y>
      <width>41</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>No</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_13">
    <property name="geometry">
     <rect>
      <x>90</x>
      <y>390</y>
      <width>91</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>SDKManager:</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_14">
    <property name="geometry">
     <rect>
      <x>186</x>
      <y>410</y>
      <width>41</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>No</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_15">
    <property name="geometry">
     <rect>
      <x>106</x>
      <y>410</y>
      <width>81</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Build-Tools:</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_16">
    <property name="geometry">
     <rect>
      <x>186</x>
      <y>430</y>
      <width>41</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>No</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_17">
    <property name="geometry">
     <rect>
      <x>126</x>
      <y>430</y>
      <width>61</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Appium:</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_18">
    <property name="geometry">
     <rect>
      <x>186</x>
      <y>450</y>
      <width>41</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>No</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_19">
    <property name="geometry">
     <rect>
      <x>110</x>
      <y>450</y>
      <width>71</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>11</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Tesseract:</string>
    </property>
   </widget>
   <widget class="QPushButton" name="button_Run">
    <property name="geometry">
     <rect>
      <x>100</x>
      <y>20</y>
      <width>71</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="styleSheet">
     <string notr="true">background-color: rgb(85, 255, 127);</string>
    </property>
    <property name="text">
     <string>Run</string>
    </property>
    <property name="icon">
     <iconset>
      <normalon>:/run/play-button.png</normalon>
     </iconset>
    </property>
   </widget>
   <widget class="QPushButton" name="button_Quit">
    <property name="geometry">
     <rect>
      <x>180</x>
      <y>20</y>
      <width>71</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="styleSheet">
     <string notr="true">background-color: rgb(255, 112, 93);</string>
    </property>
    <property name="text">
     <string>Quit</string>
    </property>
    <property name="icon">
     <iconset>
      <normalon>:/quit/quit.png</normalon>
     </iconset>
    </property>
   </widget>
   <widget class="QPushButton" name="button_Report">
    <property name="geometry">
     <rect>
      <x>280</x>
      <y>20</y>
      <width>101</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="styleSheet">
     <string notr="true">background-color: rgb(199, 199, 199);</string>
    </property>
    <property name="text">
     <string>See Report</string>
    </property>
    <property name="icon">
     <iconset>
      <normalon>:/report/seo-report.png</normalon>
     </iconset>
    </property>
   </widget>
   <widget class="QPushButton" name="button_Doc">
    <property name="geometry">
     <rect>
      <x>390</x>
      <y>20</y>
      <width>121</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="styleSheet">
     <string notr="true">background-color: rgb(199, 199, 199);</string>
    </property>
    <property name="text">
     <string>Read the Doc</string>
    </property>
    <property name="icon">
     <iconset>
      <normalon>:/doc/document.png</normalon>
     </iconset>
    </property>
   </widget>
   <widget class="QPushButton" name="button_Support">
    <property name="geometry">
     <rect>
      <x>650</x>
      <y>20</y>
      <width>131</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="styleSheet">
     <string notr="true">background-color: rgb(199, 199, 199);</string>
    </property>
    <property name="text">
     <string>Contact Support</string>
    </property>
    <property name="icon">
     <iconset>
      <normalon>:/support/question.png</normalon>
     </iconset>
    </property>
   </widget>
   <widget class="QLabel" name="label_4">
    <property name="geometry">
     <rect>
      <x>430</x>
      <y>140</y>
      <width>31</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>20</pointsize>
     </font>
    </property>
    <property name="text">
     <string>3.</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_3_Title">
    <property name="geometry">
     <rect>
      <x>460</x>
      <y>146</y>
      <width>331</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>16</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Connect your Smartphone(s)</string>
    </property>
   </widget>
   <widget class="QPlainTextEdit" name="plainTextEdit_Smartphones">
    <property name="geometry">
     <rect>
      <x>440</x>
      <y>175</y>
      <width>311</width>
      <height>171</height>
     </rect>
    </property>
    <property name="plainText">
     <string>No smartphones were detected... Please verify you enable USB debug mode and you plug correctly your smartphone(s) to your computer through USB, and press the &quot;SCAN&quot; button.</string>
    </property>
   </widget>
   <widget class="QPushButton" name="button_ScanSmartphones">
    <property name="geometry">
     <rect>
      <x>660</x>
      <y>355</y>
      <width>91</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>16</pointsize>
     </font>
    </property>
    <property name="styleSheet">
     <string notr="true">background-color: rgb(199, 199 199);</string>
    </property>
    <property name="text">
     <string>Scan</string>
    </property>
    <property name="icon">
     <iconset>
      <normalon>:/scan/search.png</normalon>
     </iconset>
    </property>
   </widget>
   <widget class="QPushButton" name="button_Videos">
    <property name="geometry">
     <rect>
      <x>520</x>
      <y>20</y>
      <width>121</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="styleSheet">
     <string notr="true">background-color: rgb(199, 199, 199);</string>
    </property>
    <property name="text">
     <string>Watch videos</string>
    </property>
    <property name="icon">
     <iconset>
      <normalon>:/whatch_videos/play.png</normalon>
     </iconset>
    </property>
   </widget>
   <widget class="QLabel" name="label_6">
    <property name="geometry">
     <rect>
      <x>430</x>
      <y>390</y>
      <width>31</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>20</pointsize>
     </font>
    </property>
    <property name="text">
     <string>4.</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_4_Title">
    <property name="geometry">
     <rect>
      <x>460</x>
      <y>396</y>
      <width>331</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>16</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Configure the tasks</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_info1">
    <property name="geometry">
     <rect>
      <x>40</x>
      <y>265</y>
      <width>201</width>
      <height>20</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Your MyUI is activated.</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_info2">
    <property name="geometry">
     <rect>
      <x>40</x>
      <y>480</y>
      <width>281</width>
      <height>20</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="text">
     <string>The softwares are correctly installed.</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_info3">
    <property name="geometry">
     <rect>
      <x>440</x>
      <y>360</y>
      <width>201</width>
      <height>20</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="text">
     <string>MyUI detected smartphones.</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_info4">
    <property name="geometry">
     <rect>
      <x>440</x>
      <y>470</y>
      <width>201</width>
      <height>20</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>10</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Some tasks were configured.</string>
    </property>
   </widget>
   <widget class="QPushButton" name="button_Config">
    <property name="geometry">
     <rect>
      <x>440</x>
      <y>430</y>
      <width>311</width>
      <height>31</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>16</pointsize>
     </font>
    </property>
    <property name="styleSheet">
     <string notr="true">background-color: rgb(199, 199 199);</string>
    </property>
    <property name="text">
     <string>Open configuration page</string>
    </property>
    <property name="icon">
     <iconset>
      <normalon>:/config/gear.png</normalon>
     </iconset>
    </property>
   </widget>
   <widget class="QLabel" name="label_HeaderMsg">
    <property name="geometry">
     <rect>
      <x>100</x>
      <y>90</y>
      <width>671</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>12</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Everything is correct. Start your MyUI by pressing the button &quot;Run&quot; in top left corner.</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_HeaderMsg_2">
    <property name="geometry">
     <rect>
      <x>220</x>
      <y>530</y>
      <width>421</width>
      <height>21</height>
     </rect>
    </property>
    <property name="font">
     <font>
      <pointsize>12</pointsize>
     </font>
    </property>
    <property name="text">
     <string>Join our community on Telegram: myurl</string>
    </property>
   </widget>
   <widget class="QLabel" name="label_7">
    <property name="geometry">
     <rect>
      <x>180</x>
      <y>525</y>
      <width>32</width>
      <height>32</height>
     </rect>
    </property>
    <property name="styleSheet">
     <string notr="true">background-image: url(:/telegram/telegram.png);</string>
    </property>
    <property name="text">
     <string/>
    </property>
   </widget>
   <widget class="Line" name="line">
    <property name="geometry">
     <rect>
      <x>10</x>
      <y>120</y>
      <width>781</width>
      <height>20</height>
     </rect>
    </property>
    <property name="orientation">
     <enum>Qt::Horizontal</enum>
    </property>
   </widget>
   <widget class="Line" name="line_2">
    <property name="geometry">
     <rect>
      <x>10</x>
      <y>500</y>
      <width>781</width>
      <height>20</height>
     </rect>
    </property>
    <property name="orientation">
     <enum>Qt::Horizontal</enum>
    </property>
   </widget>
  </widget>
  <widget class="QStatusBar" name="statusbar"/>
 </widget>
 <resources>
  <include location="logo.qrc"/>
  <include location="telegram.qrc"/>
  <include location="config.qrc"/>
  <include location="scan.qrc"/>
  <include location="save.qrc"/>
  <include location="watch_videos.qrc"/>
  <include location="support.qrc"/>
  <include location="doc.qrc"/>
  <include location="report.qrc"/>
  <include location="quit.qrc"/>
  <include location="run.qrc"/>
 </resources>
 <connections/>
</ui>

这是一个qrc文件(所有qrc文件的源代码都相同,除了映像文件名和前缀正在更改)。

logo.qrc:

<RCC>
  <qresource prefix="logo">
    <file>logo_MyUI_300.jpg</file>
  </qresource>
</RCC>

我试过的

我从MyUI.ui文件编辑了图像路径,以添加“ / ui /”文件夹路径,但是它没有任何改变。我在qrc文件中做了相同的操作,没有任何变化。

您有什么想法请阻止图像的显示吗?

永乐

uic.loadUi函数与Qt Designate用于显示预览的方法不同,uic.loadUi函数会生成python动态允许的类和属性,因此它需要您使用pyrcc5编译rc并将其导入到脚本中,例如例:

pyrcc5 ui/logo.qrc -o logo_rc.py
from PyQt5 import QtWidgets, uic

import logo_rc

gui = QtWidgets.QApplication([])
ui=uic.loadUi('ui/MyUI.ui')

ui.show()
gui.exec()

本文收集自互联网,转载请注明来源。

如有侵权,请联系[email protected] 删除。

编辑于
0

我来说两句

0条评论
登录后参与评论

相关文章

来自分类Dev

为什么此Python / Qt代码的执行是异步的

来自分类Dev

为什么此Python代码执行两次?

来自分类Dev

为什么我在eclipse评论后仍然执行python代码

来自分类Dev

为什么我的函数不能在 python 代码中执行?

来自分类Dev

为什么执行溢出计算时Python冻结?

来自分类Dev

为什么在执行`a ='python'`时python插入字符串,而源代码未显示该字符串?

来自分类Dev

为什么在执行Python Tkinter计算器的代码时出现错误?

来自分类Dev

为什么我在 C++ 和 Python 中执行 RSA 签名时得到不同的签名?

来自分类Dev

为什么在C和Java中针对同一代码显示不同的行为?

来自分类Dev

未执行 Javascript 函数。为什么?

来自分类Dev

为什么需要execstack在堆上执行代码?

来自分类Dev

为什么不执行此JavaScript代码?

来自分类Dev

为什么这些代码不执行?

来自分类Dev

为什么此代码按顺序执行?

来自分类Dev

异步编程,为什么不执行代码

来自分类Dev

为什么while(0)不执行代码?

来自分类Dev

Python奇怪的问题集思广益-为什么一条线有时不执行?

来自分类Dev

为什么仅在python模块使用cv.imshow()时才执行C#回调?

来自分类Dev

Python奇怪的问题集思广益-为什么一条线有时不执行?

来自分类Dev

Python学习-if,elif和else语句-某些条件为true但未执行(打印),为什么?

来自分类Dev

为什么在定义时执行类的主体?

来自分类Dev

为什么在使用QT5时收到以下错误?

来自分类Dev

为什么在使用QT5时收到以下错误?

来自分类Dev

尽管python代码正在执行而没有任何错误,为什么该图标没有显示在系统任务栏中?

来自分类Dev

在python中,为什么仅在调用另一个模块的方法时才执行类主体中的代码?

来自分类Dev

为什么在执行模拟方法时未调用模拟通知?

来自分类Dev

为什么以下代码编译和执行成功?

来自分类Dev

OpenGL QT 4代码在QT5中不显示QLogo(Helloworld示例)

来自分类Dev

为什么它一直显示未定义但已定义的Python 3代码错误类?

Related 相关文章

  1. 1

    为什么此Python / Qt代码的执行是异步的

  2. 2

    为什么此Python代码执行两次?

  3. 3

    为什么我在eclipse评论后仍然执行python代码

  4. 4

    为什么我的函数不能在 python 代码中执行?

  5. 5

    为什么执行溢出计算时Python冻结?

  6. 6

    为什么在执行`a ='python'`时python插入字符串,而源代码未显示该字符串?

  7. 7

    为什么在执行Python Tkinter计算器的代码时出现错误?

  8. 8

    为什么我在 C++ 和 Python 中执行 RSA 签名时得到不同的签名?

  9. 9

    为什么在C和Java中针对同一代码显示不同的行为?

  10. 10

    未执行 Javascript 函数。为什么?

  11. 11

    为什么需要execstack在堆上执行代码?

  12. 12

    为什么不执行此JavaScript代码?

  13. 13

    为什么这些代码不执行?

  14. 14

    为什么此代码按顺序执行?

  15. 15

    异步编程,为什么不执行代码

  16. 16

    为什么while(0)不执行代码?

  17. 17

    Python奇怪的问题集思广益-为什么一条线有时不执行?

  18. 18

    为什么仅在python模块使用cv.imshow()时才执行C#回调?

  19. 19

    Python奇怪的问题集思广益-为什么一条线有时不执行?

  20. 20

    Python学习-if,elif和else语句-某些条件为true但未执行(打印),为什么?

  21. 21

    为什么在定义时执行类的主体?

  22. 22

    为什么在使用QT5时收到以下错误?

  23. 23

    为什么在使用QT5时收到以下错误?

  24. 24

    尽管python代码正在执行而没有任何错误,为什么该图标没有显示在系统任务栏中?

  25. 25

    在python中,为什么仅在调用另一个模块的方法时才执行类主体中的代码?

  26. 26

    为什么在执行模拟方法时未调用模拟通知?

  27. 27

    为什么以下代码编译和执行成功?

  28. 28

    OpenGL QT 4代码在QT5中不显示QLogo(Helloworld示例)

  29. 29

    为什么它一直显示未定义但已定义的Python 3代码错误类?

热门标签

归档