| 
    BornAgain
    1.19.0
    
   Simulate and fit neutron and x-ray scattering at grazing incidence 
   | 
 
Public Types | |
| enum | EPortDirection { INPUT , OUTPUT } | 
| port direction  More... | |
| enum | EPortType {  DEFAULT , INTERFERENCE , PARTICLE_LAYOUT , FORM_FACTOR , TRANSFORMATION }  | 
| type of ports, same type can be connected together  More... | |
Public Member Functions | |
| NodeEditorPort (QGraphicsItem *parent=0, const QString &name="unnamed", EPortDirection direction=INPUT, EPortType port_type=DEFAULT) | |
| virtual | ~NodeEditorPort () | 
| void | append (NodeEditorConnection *connection) | 
| EPortType | getPortType () const | 
| bool | isConnected () | 
| bool | isConnected (NodeEditorPort *) | 
| bool | isInput () | 
| bool | isOutput () | 
| const QString & | portName () const | 
| void | remove (NodeEditorConnection *connection) | 
| void | setLabel (QString name) | 
| virtual int | type () const | 
Static Public Member Functions | |
| static QColor | getPortTypeColor (NodeEditorPort::EPortType port_type) | 
Protected Member Functions | |
| QVariant | itemChange (GraphicsItemChange change, const QVariant &value) | 
Private Attributes | |
| QColor | m_color | 
| QVector< NodeEditorConnection * > | m_connections | 
| EPortDirection | m_direction | 
| QGraphicsTextItem * | m_label | 
| int | m_margin | 
| QString | m_name | 
| EPortType | m_port_type | 
| int | m_radius | 
Definition at line 31 of file NodeEditorPort.h.
type of ports, same type can be connected together
| Enumerator | |
|---|---|
| DEFAULT | |
| INTERFERENCE | |
| PARTICLE_LAYOUT | |
| FORM_FACTOR | |
| TRANSFORMATION | |
Definition at line 34 of file NodeEditorPort.h.
| NodeEditorPort::NodeEditorPort | ( | QGraphicsItem * | parent = 0,  | 
        
| const QString & | name = "unnamed",  | 
        ||
| NodeEditorPort::EPortDirection | direction = INPUT,  | 
        ||
| NodeEditorPort::EPortType | port_type = DEFAULT  | 
        ||
| ) | 
Definition at line 23 of file NodeEditorPort.cpp.
References getPortTypeColor(), m_color, m_margin, m_name, m_radius, setLabel(), and StyleUtils::SizeOfLetterM().
      
  | 
  virtual | 
Definition at line 52 of file NodeEditorPort.cpp.
References m_connections.
| void NodeEditorPort::append | ( | NodeEditorConnection * | connection | ) | 
Definition at line 77 of file NodeEditorPort.cpp.
References m_connections.
Referenced by NodeEditorConnection::setPort1(), and NodeEditorConnection::setPort2().
      
  | 
  inline | 
Definition at line 93 of file NodeEditorPort.h.
References m_port_type.
Referenced by DesignerScene::onEstablishedConnection(), and NodeEditor::processMouseRelease().
      
  | 
  static | 
Definition at line 91 of file NodeEditorPort.cpp.
References DEFAULT, FORM_FACTOR, INTERFERENCE, PARTICLE_LAYOUT, and TRANSFORMATION.
Referenced by NodeEditorPort().
      
  | 
  inline | 
Definition at line 88 of file NodeEditorPort.h.
References m_connections.
| bool NodeEditorPort::isConnected | ( | NodeEditorPort * | other | ) | 
Definition at line 82 of file NodeEditorPort.cpp.
References m_connections.
Referenced by ConnectableView::connectInputPort(), and NodeEditor::processMouseRelease().
| bool NodeEditorPort::isInput | ( | ) | 
Definition at line 66 of file NodeEditorPort.cpp.
References isOutput().
Referenced by NodeEditorConnection::inputPort().
| bool NodeEditorPort::isOutput | ( | ) | 
Definition at line 61 of file NodeEditorPort.cpp.
References m_direction, and OUTPUT.
Referenced by isInput(), NodeEditorConnection::outputPort(), NodeEditor::processMouseRelease(), setLabel(), and ConnectableView::setPortCoordinates().
      
  | 
  protected | 
      
  | 
  inline | 
| void NodeEditorPort::remove | ( | NodeEditorConnection * | connection | ) | 
Definition at line 71 of file NodeEditorPort.cpp.
References m_connections.
Referenced by NodeEditorConnection::~NodeEditorConnection().
| void NodeEditorPort::setLabel | ( | QString | name | ) | 
Definition at line 120 of file NodeEditorPort.cpp.
References DesignerHelper::getPortFontSize(), isOutput(), m_label, m_margin, m_radius, and RealSpace::Particles::name().
Referenced by NodeEditorPort(), and ILayerView::updateLabel().
      
  | 
  inlinevirtual | 
      
  | 
  private | 
Definition at line 71 of file NodeEditorPort.h.
Referenced by NodeEditorPort().
      
  | 
  private | 
Definition at line 74 of file NodeEditorPort.h.
Referenced by ~NodeEditorPort(), append(), isConnected(), itemChange(), and remove().
      
  | 
  private | 
Definition at line 69 of file NodeEditorPort.h.
Referenced by isOutput().
      
  | 
  private | 
Definition at line 75 of file NodeEditorPort.h.
Referenced by setLabel().
      
  | 
  private | 
Definition at line 73 of file NodeEditorPort.h.
Referenced by NodeEditorPort(), and setLabel().
      
  | 
  private | 
Definition at line 68 of file NodeEditorPort.h.
Referenced by NodeEditorPort(), and portName().
      
  | 
  private | 
Definition at line 70 of file NodeEditorPort.h.
Referenced by getPortType().
      
  | 
  private | 
Definition at line 72 of file NodeEditorPort.h.
Referenced by NodeEditorPort(), and setLabel().