[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: A newbie question about QXEmbed
From:       Robert Wood <robert.wood () apostrophe ! co ! uk>
Date:       2008-06-08 13:59:53
Message-ID: 484BE5D9.5060508 () apostrophe ! co ! uk
[Download RAW message or body]

Koos, dank u wel, dank u wel!

That works a treat now. I can embed it quite into a little frame on my 
application as well, it's just exactly what I wanted and is actually 
quite simple once you know the syntax!



koos vriezen wrote:
> 2008/6/8 Otávio Souza <aragao.otavio@gmail.com>:
>   
>> You didn't forget the QProcess::start(), you did it at if ( !mp->start() )
>>
>> Try to show up the window first, than you start the mplayer process, you can
>> try to start another app, like kwrite ou anything else
>>
>> If this doesn't work, try to qDebug the QXEmbed winId, and do mplayer by
>> hand, copy and paste with the command
>>     
>
> Really, you don't need QXEmbed. Here is a minimalistic mplayer frontend:
>
> #include <qapplication.h>
> #include <qwidget.h>
>
> int main( int argc, char **argv ) {
>     QApplication app( argc, argv );
>     QWidget *window = new QWidget;
>     window->show();
>     window->setUpdatesEnabled( false ); //call this when you start the
> mplayer process
>     qDebug( "Window id=%d", window->winId() );
>     app.exec();
>     return 0;
> }
>
> g++ -o qmplayer qmplayer.cpp -I/usr/share/qt3/include -lqt-mt
>
> run ./qmplayer
> and from another shell
> mplayer -wid <id-that-is-printed> moviefile
>
>
>   

 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic