Skip to content

VSTi plugins don't show in Subwindow on Qt5 build (probably only X11) #2855

@BaraMGB

Description

@BaraMGB

screenshot_20160616_145731

Qt 5 bug:

the vst window will not be caught by the subwindow. With Qt4 we use QX11EmbedContainer for catching the vst window in our subwindow. QX11EmbedContainer is gone in Qt5.

https://github.com/LMMS/lmms/blob/master/plugins/vst_base/VstPlugin.cpp#L228


#ifdef LMMS_BUILD_LINUX
    if( m_pluginWindowID == 0 )
    {
        return;
    }

    m_pluginWidget = new QWidget( _parent );
    m_pluginWidget->setFixedSize( m_pluginGeometry );
    m_pluginWidget->setWindowTitle( name() );
    if( _parent == NULL )
    {
        vstSubWin * sw = new vstSubWin(
                    gui->mainWindow()->workspace() );
        if( isEffect )
        {
            sw->setAttribute( Qt::WA_TranslucentBackground );
            sw->setWindowFlags( Qt::FramelessWindowHint );
            sw->setWidget( m_pluginWidget );
#if QT_VERSION < 0x050000
            QX11EmbedContainer * xe = new QX11EmbedContainer( sw );
            xe->embedClient( m_pluginWindowID );
            xe->setFixedSize( m_pluginGeometry );
            xe->show();
#endif
        } 
        else
        {
            sw->setWindowFlags( Qt::WindowCloseButtonHint );
            sw->setWidget( m_pluginWidget );

#if QT_VERSION < 0x050000
            QX11EmbedContainer * xe = new QX11EmbedContainer( sw );
            xe->embedClient( m_pluginWindowID );
            xe->setFixedSize( m_pluginGeometry );
            xe->move( 4, 24 );
            xe->show();
#endif

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions