1
0
mirror of https://github.com/YosysHQ/nextpnr.git synced 2026-01-26 20:22:44 +00:00

initial import of python-console

This commit is contained in:
Miodrag Milanovic
2018-06-28 13:16:53 +02:00
parent 66670831b8
commit c63274342f
28 changed files with 2120 additions and 0 deletions

View File

@@ -0,0 +1,36 @@
#include <iostream>
#include <QApplication>
#include <QMainWindow>
#include <QWidget>
#include <QGridLayout>
#include <QTextEdit>
#include "Console.h"
#include "Interpreter.h"
Console* console;
void SetupWindow( int argc, char *argv[] )
{
QMainWindow* window = new QMainWindow;
window->resize( 800, 600 );
QWidget* centralWidget = new QWidget(window);
QGridLayout* layout = new QGridLayout(centralWidget);
console = new Console;
layout->addWidget(console, 0, 0, 1, 1);
window->setCentralWidget(centralWidget);
window->show( );
}
int main( int argc, char *argv[] )
{
QApplication app( argc, argv );
Interpreter::Initialize( );
SetupWindow( argc, argv );
bool res = app.exec( );
delete console;
Interpreter::Finalize( );
return res;
}