i love batch batch is my first language its so easy ive writen a program better than this terminal i will learn bash kool is it in any way graphicaly capable
i love batch batch is my first language its so easy ive writen a program better than this terminal i will learn bash kool is it in any way graphicaly capable
iaaaaaaasoqjdokasjfidsjfi
hehe, graphical stuff and bash are a no go, but its for scripting not really actually application use. I would suggest python or ruby for gui stuff.
i expected that but ppl say its better than batch um can you direct me to a site to learn that bash
iaaaaaaasoqjdokasjfidsjfi
A version in Qt4.
nameInput.hpp
nameInput.cppCode:#ifndef NAMEINPUT_HPP #define NAMEINPUT_HPP #include <QLineEdit> #include <QStatusBar> #include <QVBoxLayout> class NameInput : public QWidget { Q_OBJECT private: QLineEdit *input_; QStatusBar *msg_; signals: void showGreeting( const QString &greeting ); private slots: void buildGreeting( const QString &name ) { emit showGreeting( "Welcome to Ubuntu, " + name ); } public: NameInput( QWidget *parent=0 ); }; #endif // NAMEINPUT_HPP
main.cppCode:#include "nameInput.hpp" NameInput::NameInput( QWidget *parent ) : QWidget( parent ), input_( new QLineEdit( tr( "Enter your name" ), this ) ), msg_( new QStatusBar( this ) ) { connect( input_, SIGNAL( textEdited( const QString & ) ), this, SLOT( buildGreeting( const QString & ) ) ); connect( this, SIGNAL( showGreeting( const QString &) ), msg_, SLOT( showMessage( const QString & ) ) ); QVBoxLayout *layout = new QVBoxLayout(); layout->addWidget( input_ ); layout->addWidget( msg_ ); setLayout( layout ); resize( sizeHint() ); };
Put everything in a seperate directory and then:Code:#include <QApplication> #include "nameInput.hpp" int main( int argc, char *argv[] ) { QApplication app( argc, argv ); NameInput nameIn; nameIn.resize( 350, 100 ); nameIn.show(); return app.exec(); }
Code:qmake -project qmake make
Eh, bite me, DoktorSeven
"Who d'you know who's lost a buttock?" --Tonks
Linux user #430538 (Machine #335692)/Ubuntu user 7858 (Machine #9033)
myAge.today = myAge.yesterday++
Are you sure you didn't miss some of the program? A similar example is much longer.
http://compsoc.dur.ac.uk/whitespace/name.ws
IBM RPGLE on the System i at V5R4M0
h Copyright('Jason Olson')
h Text('helloubuntu')
d Response s 10a
/free
Dsply ('Hi! What Is Your Name?') ' ' Response;
Dsply ('Hello ' + %trim(Response) + '! Welcome to Ubuntu!');
*inlr = *on;
/end-free
The title of the thread is 'Ubuntu in every programming language'
It does not say that the language must 'RUN' on ubuntu (even though this could run, potentially, using Wine), it just has to be a programming language. Now, Windows Shell Scripting (or whatever you want to call it) might be debatable when it comes to the clinical definition of a programming language, but the way I look at it, if bash makes it, so should any scripting language, even one as pathetic as our old friend cmd.exe.
for beer in $(ls /home/fridge); dodrink $beerdone
REXX
Code:say "Hi! What is your name?" name=Linein() say 'Hello 'name'! Welcome to Ubuntu!'
Bookmarks