change Motif to VC? 
Author Message
 change Motif to VC?

Hello:
     I will change Motif X-window to Microsoft  NT application ?Anyone have
good sugesstion and good Website to recommend ?
                                Thank you.


Sat, 05 Jun 2004 12:19:28 GMT  
 change Motif to VC?
I've done it. It wasn't too bad; the problems were mostly in fonts (it was
font-sensitive).

What we did was put the Motif/X expert on one side of the table and me on the other. I'd
had a couple days to preview the code. We then said "how do you do this?" and wrote an
abstract interface (e.g., for menu handling) that was the same API for Windows and X. Then
he extracted the X code and wrote the X-based subroutines and I wrote the Windows-based
subroutines. These were kept in two different subproject directories (I don't believe in
conditional compilation for producing multiple versions). All common code remained in the
main (shared) source, so keeping versions up-to-date by having to change two locations was
a non-issue.

It took us about a week to do 98% of the translation, and about another week to get the
fonts to work properly.

Key areas of differences:
        menu handling
        object message handling (WM_ messages, if you will)
        graphics (details, not abstract)
        fonts
        kill signal
        file I/O (parsing file names, opening files)

Also, I duplicated all the X/Motif dialogs as resources; we only had a few (like 6, if I
recall) and most of them fell naturally into the subroutines for the above.
                                joe

Quote:

>Hello:
>     I will change Motif X-window to Microsoft  NT application ?Anyone have
>good sugesstion and good Website to recommend ?
>                                Thank you.

Joseph M. Newcomer [MVP]

Web: http://www3.pgh.net/~newcomer
MVP Tips: http://www3.pgh.net/~newcomer/mvp_tips.htm


Sat, 05 Jun 2004 14:06:02 GMT  
 change Motif to VC?
Thank your help.but I am unfamiliar with two.Could you give me sth
example?And tell know
where to  find the difference and  the map of  motif API with win32 API?

I have used 2-screen card ,in motif used 2 process, in NT how I can witre 2
thread?

For my greed wish ,could u give me the detail

Quote:
> menu handling
> object message handling (WM_ messages, if you will)
> graphics (details, not abstract)
> fonts
> kill signal
> file I/O (parsing file names, opening files)

  difference to write an essay .
 I think many people like to read.
            wu Jun



Quote:
> I've done it. It wasn't too bad; the problems were mostly in fonts (it was
> font-sensitive).

> What we did was put the Motif/X expert on one side of the table and me on
the other. I'd
> had a couple days to preview the code. We then said "how do you do this?"
and wrote an
> abstract interface (e.g., for menu handling) that was the same API for
Windows and X. Then
> he extracted the X code and wrote the X-based subroutines and I wrote the
Windows-based
> subroutines. These were kept in two different subproject directories (I
don't believe in
> conditional compilation for producing multiple versions). All common code
remained in the
> main (shared) source, so keeping versions up-to-date by having to change
two locations was
> a non-issue.

> It took us about a week to do 98% of the translation, and about another
week to get the
> fonts to work properly.

> Key areas of differences:
> menu handling
> object message handling (WM_ messages, if you will)
> graphics (details, not abstract)
> fonts
> kill signal
> file I/O (parsing file names, opening files)

> Also, I duplicated all the X/Motif dialogs as resources; we only had a few
(like 6, if I
> recall) and most of them fell naturally into the subroutines for the
above.
> joe



> >Hello:
> >     I will change Motif X-window to Microsoft  NT application ?Anyone
have
> >good sugesstion and good Website to recommend ?
> >                                Thank you.

> Joseph M. Newcomer [MVP]

> Web: http://www3.pgh.net/~newcomer
> MVP Tips: http://www3.pgh.net/~newcomer/mvp_tips.htm



Sat, 05 Jun 2004 16:46:36 GMT  
 change Motif to VC?
Chaning the basic architecture (from 2-process to 2-thread, for example) is a really
fundamental change, not a superficial one. This has nothing to do with X/Motif moving to
Windows; this is a complete redesign of the architecture, and that is a MUCH more
difficult task. As to how to write "two threads", the answer is, it is as hard as your
application demands, and that varies from trivial to "an expert on Windows threading
wouldn't touch it for any amount of money [as long as success was required]"

And no, I can't give you a lot of details (ghastly commercial plug: I can be hired; I'm a
consultant) but the rough form is:
        menu handling: You have to write handlers that call a "standard handler" in
                the same way X/Motif calls it. This involved only changing the setup
                for X, but required a complicated mapping (akin to MESSAGE_MAP)
                in Windows, using the same setup calls as X
        object message handling: this was pretty easy, actually. We had to add
                some new handlers for Windows, but otherwise I think we knocked
                all of this off in an afternoon
        graphics: for each graphical operation, write a subroutine to do it. In the
                subroutine, call the native call. For example, we wrote handlers
                for MoveTo, LineTo, Rectangle, PolyLine, and a couple others.
                While the application was fairly graphics intensive, it didn't require
                a lot of sophistication
        fonts: We had an early version of X with primitive font capabilities, so the
                X application did a lot of the font stuff that Windows does
                automatically. The problem was that I had to draw a word at a
                time in some cases, using track kerning, to get the WYSIWYG
                appearance demanded by the application (the fonts were
                not compatible in terms of widths)
        kill signal: handle WM_CLOSE, WM_QUERYENDSESSION, and WM_ENDSESSION
                this was actually fairly awful, because signal is a truly awful mechanism,
                and coming up with a way to get around it, given how it had been coded,
                was a serious reprogramming issue.
        file I/O: the ways in which file names were parsed (e.g., "/" vs. "\"), and the
                file open dialog were the issues. Nothing deep.

Since this was nearly eight years ago, I don't have much more detailed recollection than
this, and I can't publish any code.
                                joe

Quote:

>Thank your help.but I am unfamiliar with two.Could you give me sth
>example?And tell know
>where to  find the difference and  the map of  motif API with win32 API?

>I have used 2-screen card ,in motif used 2 process, in NT how I can witre 2
>thread?

>For my greed wish ,could u give me the detail
>> menu handling
>> object message handling (WM_ messages, if you will)
>> graphics (details, not abstract)
>> fonts
>> kill signal
>> file I/O (parsing file names, opening files)
>  difference to write an essay .
> I think many people like to read.
>            wu Jun



>> I've done it. It wasn't too bad; the problems were mostly in fonts (it was
>> font-sensitive).

>> What we did was put the Motif/X expert on one side of the table and me on
>the other. I'd
>> had a couple days to preview the code. We then said "how do you do this?"
>and wrote an
>> abstract interface (e.g., for menu handling) that was the same API for
>Windows and X. Then
>> he extracted the X code and wrote the X-based subroutines and I wrote the
>Windows-based
>> subroutines. These were kept in two different subproject directories (I
>don't believe in
>> conditional compilation for producing multiple versions). All common code
>remained in the
>> main (shared) source, so keeping versions up-to-date by having to change
>two locations was
>> a non-issue.

>> It took us about a week to do 98% of the translation, and about another
>week to get the
>> fonts to work properly.

>> Key areas of differences:
>> menu handling
>> object message handling (WM_ messages, if you will)
>> graphics (details, not abstract)
>> fonts
>> kill signal
>> file I/O (parsing file names, opening files)

>> Also, I duplicated all the X/Motif dialogs as resources; we only had a few
>(like 6, if I
>> recall) and most of them fell naturally into the subroutines for the
>above.
>> joe



>> >Hello:
>> >     I will change Motif X-window to Microsoft  NT application ?Anyone
>have
>> >good sugesstion and good Website to recommend ?
>> >                                Thank you.

>> Joseph M. Newcomer [MVP]

>> Web: http://www3.pgh.net/~newcomer
>> MVP Tips: http://www3.pgh.net/~newcomer/mvp_tips.htm

Joseph M. Newcomer [MVP]

Web: http://www3.pgh.net/~newcomer
MVP Tips: http://www3.pgh.net/~newcomer/mvp_tips.htm


Sun, 06 Jun 2004 02:33:01 GMT  
 change Motif to VC?
Thank your help.


Quote:
> Chaning the basic architecture (from 2-process to 2-thread, for example)
is a really
> fundamental change, not a superficial one. This has nothing to do with
X/Motif moving to
> Windows; this is a complete redesign of the architecture, and that is a
MUCH more
> difficult task. As to how to write "two threads", the answer is, it is as
hard as your
> application demands, and that varies from trivial to "an expert on Windows
threading
> wouldn't touch it for any amount of money [as long as success was
required]"

> And no, I can't give you a lot of details (ghastly commercial plug: I can
be hired; I'm a
> consultant) but the rough form is:
> menu handling: You have to write handlers that call a "standard handler"
in
> the same way X/Motif calls it. This involved only changing the setup
> for X, but required a complicated mapping (akin to MESSAGE_MAP)
> in Windows, using the same setup calls as X
> object message handling: this was pretty easy, actually. We had to add
> some new handlers for Windows, but otherwise I think we knocked
> all of this off in an afternoon
> graphics: for each graphical operation, write a subroutine to do it. In
the
> subroutine, call the native call. For example, we wrote handlers
> for MoveTo, LineTo, Rectangle, PolyLine, and a couple others.
> While the application was fairly graphics intensive, it didn't require
> a lot of sophistication
> fonts: We had an early version of X with primitive font capabilities, so
the
> X application did a lot of the font stuff that Windows does
> automatically. The problem was that I had to draw a word at a
> time in some cases, using track kerning, to get the WYSIWYG
> appearance demanded by the application (the fonts were
> not compatible in terms of widths)
> kill signal: handle WM_CLOSE, WM_QUERYENDSESSION, and WM_ENDSESSION
> this was actually fairly awful, because signal is a truly awful mechanism,
> and coming up with a way to get around it, given how it had been coded,
> was a serious reprogramming issue.
> file I/O: the ways in which file names were parsed (e.g., "/" vs. "\"),
and the
> file open dialog were the issues. Nothing deep.

> Since this was nearly eight years ago, I don't have much more detailed
recollection than
> this, and I can't publish any code.
> joe



> >Thank your help.but I am unfamiliar with two.Could you give me sth
> >example?And tell know
> >where to  find the difference and  the map of  motif API with win32 API?

> >I have used 2-screen card ,in motif used 2 process, in NT how I can witre
2
> >thread?

> >For my greed wish ,could u give me the detail
> >> menu handling
> >> object message handling (WM_ messages, if you will)
> >> graphics (details, not abstract)
> >> fonts
> >> kill signal
> >> file I/O (parsing file names, opening files)
> >  difference to write an essay .
> > I think many people like to read.
> >            wu Jun



> >> I've done it. It wasn't too bad; the problems were mostly in fonts (it
was
> >> font-sensitive).

> >> What we did was put the Motif/X expert on one side of the table and me
on
> >the other. I'd
> >> had a couple days to preview the code. We then said "how do you do
this?"
> >and wrote an
> >> abstract interface (e.g., for menu handling) that was the same API for
> >Windows and X. Then
> >> he extracted the X code and wrote the X-based subroutines and I wrote
the
> >Windows-based
> >> subroutines. These were kept in two different subproject directories (I
> >don't believe in
> >> conditional compilation for producing multiple versions). All common
code
> >remained in the
> >> main (shared) source, so keeping versions up-to-date by having to
change
> >two locations was
> >> a non-issue.

> >> It took us about a week to do 98% of the translation, and about another
> >week to get the
> >> fonts to work properly.

> >> Key areas of differences:
> >> menu handling
> >> object message handling (WM_ messages, if you will)
> >> graphics (details, not abstract)
> >> fonts
> >> kill signal
> >> file I/O (parsing file names, opening files)

> >> Also, I duplicated all the X/Motif dialogs as resources; we only had a
few
> >(like 6, if I
> >> recall) and most of them fell naturally into the subroutines for the
> >above.
> >> joe

> >> On Tue, 18 Dec 2001 12:19:28 +0800, "junwu"


- Show quoted text -

Quote:

> >> >Hello:
> >> >     I will change Motif X-window to Microsoft  NT application ?Anyone
> >have
> >> >good sugesstion and good Website to recommend ?
> >> >                                Thank you.

> >> Joseph M. Newcomer [MVP]

> >> Web: http://www3.pgh.net/~newcomer
> >> MVP Tips: http://www3.pgh.net/~newcomer/mvp_tips.htm

> Joseph M. Newcomer [MVP]

> Web: http://www3.pgh.net/~newcomer
> MVP Tips: http://www3.pgh.net/~newcomer/mvp_tips.htm



Sun, 06 Jun 2004 08:38:01 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. motif and fork ()

2. Using X / Motif to write to Java windows / canvases

3. C/Motif newbie help

4. Qt for Motif

5. compiling fortran with Motif

6. Windows NT and X-Windows/Motif

7. Inquiry on sample Motif code

8. US-WI- C, UNIX, MOTIF - Frontier Systems, Inc.

9. Updating Motif Simple Option Menus?

10. I NEED SOMEONE WHO CAN PROGRAM GRAPHICS - MOTIF

11. Problem statically linking w/ X/Motif and AIX

12. motif programming newsgroup

 

 
Powered by phpBB® Forum Software