Jump to content

Search the Community

Showing results for tags 'python qt'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Lounge/General chat
    • Education
    • Jobs
    • Marketplace
  • Houdini
    • General Houdini Questions
    • Effects
    • Modeling
    • Animation & Rigging
    • Lighting & Rendering + Solaris!
    • Compositing
    • Games
    • Tools (HDA's etc.)
  • Coders Corner
    • HDK : Houdini Development Kit
    • Scripting
    • Shaders
  • Art and Challenges
    • Finished Work
    • Work in Progress
    • VFX Challenge
    • Effects Challenge Archive
  • Systems and Other Applications
    • Other 3d Packages
    • Operating Systems
    • Hardware
    • Pipeline
  • od|force
    • Feedback, Suggestions, Bugs

Product Groups

There are no results to display.


Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Skype


Name


Location


Interests

Found 1 result

  1. Hello guys, I have some problems about Pyside, I was trying to write button Background, even if use the setstylesheet , but nothing happen with my houdini, if the coding run in houdini 16.0 that ok for result. Current version is 16.5 who knows real problem, it's bug ? from PySide2.QtWidgets import * from PySide2.QtCore import * import os class demo(QWidget): def __init__(self): super(demo,self).__init__() self.setWindowFlags(Qt.WindowStaysOnTopHint) self.setWindowTitle("import_Geo") self.setUI() def setUI(self): La =QWidget(self) Main=QVBoxLayout(La) Grid=QGridLayout() Box =QHBoxLayout() Main.addLayout(Grid) Main.addLayout(Box) self.setLayout(Main) self.setGeometry(300,300,300,150) Menu_Title = QLabel("Choose_type:",self) Path_floder= QLabel("Path_flode:",self) Prefix= QLabel("Enter_Prefix:",self) self.Enter_Prefix=QLineEdit("",self) self.Enter_line = QLineEdit("",self) self.Menu=QComboBox(self) self.Menu.addItem("obj") self.Menu.addItem("abc") Button_import=QPushButton("Choose_path",self) Button_import.setToolTip("Choose your floder please") Grid.addWidget(Path_floder,1,0) Grid.addWidget(self.Enter_line,1,1) Grid.addWidget(Menu_Title,0,0) Grid.addWidget(self.Menu,0,1) Grid.addWidget(Button_import,0,2) Grid.addWidget(self.Enter_Prefix,2,1) Grid.addWidget(Prefix,2,0) Grid.setRowStretch(2,1) Button_import.setStyleSheet("QPushButton{color:rgb(0,0,0);background-color:rgb(140,140,140)}") self.setStyleSheet("background-color:rgb(140,140,140)") self.Enter_Prefix.setStyleSheet("QLineEdit{border:rgba(0,0,0,100%)}") Box.addStretch(1) self.button =QPushButton("OK",self) button1 =QPushButton("Cancel",self) Box.addWidget(self.button) Box.addWidget(button1) Button_import.clicked.connect(self.Click) #if self.button.isChecked(): #self.Menu.activated[str].connect(self.text) button1.clicked.connect(self.close) self.Menu.activated[str].connect(self.click_ok) self.button.clicked.connect(self.close) def text(self): Postfix=self.Menu.currentText() Prefix_name=self.Enter_Prefix.text() if Postfix=="abc" : a=hou.node("/obj").createNode("geo") a.node('file1').destroy() merge=a.createNode("merge") Output=a.createNode("null") counter=0 for file in self.dir: if file.endswith(".abc"): if file.startswith(Prefix_name): file_name=file.split(".")[0] full_path= self.path+file node =a.createNode("alembic") node.parm("fileName").set(full_path) node.setColor(hou.Color(1,1,0)) node.setName(file_name) merge.setInput(counter,node) Output.setInput(0,merge) Output.setColor(hou.Color(0,0,0)) counter+=1 elif Postfix=="obj": Output=a.createNode("null") a=hou.node("/obj").createNode("geo") a.node('file1').destroy() merge=a.createNode("merge") counter=0 for file in self.dir: if file.endswith(".obj"): if file.startswith(Prefix_name): file_name=file.split(".")[0] full_path= self.path+file node =a.createNode("file") node.parm("file").set(full_path) node.setColor(hou.Color(0.9,0,0)) node.setName(file_name) merge.setInput(counter,node) Output.setInput(0,merge) Output.setColor(hou.Color(0,0,0)) counter+=1 def click_ok(self): self.button.clicked.connect(self.text) def Click(self): self.path =hou.ui.selectFile(file_type=hou.fileType.Directory) self.Enter_line.setText(self.path) self.dir=os.listdir(self.path) showdemo=demo() showdemo.show() this is my coding if who knows reason i need your help. Cheers guys.
×
×
  • Create New...