Sponsored Content
Full Discussion: Motif gui programming !
Top Forums UNIX for Beginners Questions & Answers Motif gui programming ! Post 303040044 by Sennenmut on Tuesday 22nd of October 2019 10:30:07 AM
Old 10-22-2019
Motif gui programming !

MOTIF GUI PROGRAMMING !
Hi there. I am a MOTIF GUI Programmer in C language.
After a longer break i have problems with the GCC compiling.
my MOTIF file is named winstack.c
I have the follow code
Code:
 gcc -o newprogram  winstack.c  -lXm -lXt -lX11

The compilation runs good.
But no executable LINUX FILE is created. except a file named newprogram.
The properties of the file in the context menue is "shared library" not "executable".
Thats my problem.
From commandline is no problem with ./newprogram. A GUI Windows is opening.
How about a real linux exe to start with one click in file explorer ???
Kindly Regards
SM
 

10 More Discussions You Might Find Interesting

1. Programming

GUI programming

I am a newbie to the *nix developer community, and was wondering if anyone has any good links on the subject of GUI programming in the X environment. Any suggestion is welcome =). (2 Replies)
Discussion started by: Solitare
2 Replies

2. Programming

Motif

Do you think that Motif programming is old...should I learn it... (3 Replies)
Discussion started by: CreamHarry
3 Replies

3. Programming

motif help

Hi everyone, I am new in motif programming and I want to learn how to program it. I use Fedora core 3 and every time I compile the program, there are always some errors appear. One of the errors said that I do not have the Xm/xxxx.h However, I do not know precisely how to install header files. I... (0 Replies)
Discussion started by: qqq
0 Replies

4. UNIX for Dummies Questions & Answers

If a is windows gui ( client), b is a unix gui ( Server for a) and c is a shell scrip

Hello all, 1) I want to have a GUI application that will call Unix shell scripts, 2) that GUI application should be able to reside on windows ( if possible) and then call Unix shell script either directly or through a server residing on unix. That is for example. If a is windows gui (... (1 Reply)
Discussion started by: hchivukula
1 Replies

5. Solaris

Motif 2.1 migration from Motif 1.2

An application was getting built using Motif 1.2 that used come along Solaris 6 OS for compiling and linking. Application is run using Motif 2.1 on Solaris 10 and it is working fine. Application compilation and linking is working fine on Solaris 10 with Motif 2.1.0 but running the application... (0 Replies)
Discussion started by: shafi2all
0 Replies

6. Programming

Python gui or C++ gui or java gui?

python gui or c++ gui or java gui? and when to use etch one? (1 Reply)
Discussion started by: kaja
1 Replies

7. Programming

MOTIF programming and X11 client !

Hi there , i am interesting in MOTIF programming. One question : Is it right that in Motif GUI programming the actions are automaticly transformed and networked to other clients over the internet without network programming necessary ? Are the commands automatic transformed by the X11... (4 Replies)
Discussion started by: Zabo
4 Replies

8. UNIX for Beginners Questions & Answers

Wanna learn native GUI programming in UNIX - Linux ?

Hi , wanna learn native GUI programming in Unix-Linux instead of Gtk and Qt. No problem. You don't need a cross platform Gui toolkit like Gtk and Qt. And the code and syntax is also not more or less than others. Check out this code for a simple mainwindow for your application that is openend in... (0 Replies)
Discussion started by: Sennenmut
0 Replies

9. UNIX for Beginners Questions & Answers

I'll be a professional MOTIF GUI programmer.

I'll be a professional MOTIF GUI programmer. And nothing will stop me. Nothing. :) (5 Replies)
Discussion started by: Sennenmut
5 Replies

10. UNIX for Beginners Questions & Answers

Motif GUI example. UNIX executable ready.

Motif GUI example. Unix executable ready. Hi , i have attached my executable GUI example file in form of a .gz file. please gunzip file before. May i ask you for check it out that it is running on your machine ? You should have "Motif" package installed. when you klick the unix executable... (4 Replies)
Discussion started by: Sennenmut
4 Replies
Wx::Thread(3pm) 					User Contributed Perl Documentation					   Wx::Thread(3pm)

NAME
Thread - using wxPerl with threads SYNOPSIS
# the order of these use()s is important use threads; use threads::shared; use Wx; my $DONE_EVENT : shared = Wx::NewEventType; my $worker = threads->create( &work ); # create frames, etc my $frame = Wx::Frame->new( ... ); EVT_COMMAND( $frame, -1, $DONE_EVENT, &done ); $app->MainLoop; sub done { my( $frame, $event ) = @_; print $event->GetData; } sub work { # ... do stuff, create a shared $result value my $threvent = new Wx::PlThreadEvent( -1, $DONE_EVENT, $result ); Wx::PostEvent( $frame, $threvent ); } # event handler sub OnCreateThread { # @_ = () is necessary to avoid "Scalars leaked" my( $self, $event ) = @_; @_ = (); threads->create( ... ); } DESCRIPTION
Threaded GUI application are somewhat different from non-GUI threaded applications in that the main thread (which runs the GUI) must never block. Also, in wxWidgets, no thread other than the main thread can manipulate GUI objects. This leads to a hybrid model where worker threads must send events to the main thread in order to change the GUI state or signal their termination. Order of module loading It's necessary for "use Wx" to happen after <use threads::shared>. Sending events from worker threads "Wx::PlThreadEvent" can be used to communicate between worker and GUI threads. The event can carry a shared value between threads. my $DONE_EVENT : shared = Wx::NewEventType; sub work { # ... do some stuff my $progress = new Wx::PlThreadEvent( -1, $DONE_EVENT, $progress ); Wx::PostEvent( $frame, $progress ); # ... do stuff, create a shared $result value my $end = new Wx::PlThreadEvent( -1, $DONE_EVENT, $result ); Wx::PostEvent( $frame, $end ); } The target of the event can be any "Wx::EvtHandler" Receiving events from worker threads "Wx::PlThreadEvent" is a command event and can be handled as such. The "->GetData" method can be used to retrieve the shared data contained inside the event. my $DONE_EVENT : shared = Wx::NewEventType; EVT_COMMAND( $frame, -1, $DONE_EVENT, &done ); sub done { my( $frame, $event ) = @_; print $event->GetData; } Creating new threads Creating new threads from event handlers works without problems except from a little snag. In order not to trigger a bug in the Perl interpreter, all event handler that directly or indirectly cause a thread creation must clean @_ before starting the thread. For example: sub OnCreateThread { my( $self, $event ) = @_; @_ = (); threads->create( ... ); } failure to do that will cause "scalars leaked" warnings from the Perl interpreter. perl v5.14.2 2007-03-16 Wx::Thread(3pm)
All times are GMT -4. The time now is 05:39 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy