Allan,
long post indeed.

Allan Rae wrote:

> I noticed you filed a report to the libsigc++ list.

Yes, I havent gotten any replies, I have not subscribed to the list but the issue
was:
libsigc++ version 0.8.5 compiles and works on cygnus b20 NT version 0.8.6 does not
compile due to a faulty configure script. I believe the issue is that configure
thinks I am using vc++. Using the old 0.8.5 configure.in to configure and compile
0.8.6 works partially - but god what a mess.... Still these problems will
certainly be overcome so no neeed to worry.

> I've cut down the number of signal and slot templates that are generated
> (Signal0-Signal2 only for now -- I don't see any need for more that number
> of parameters in our code [one return + two parameters] although that may
> change after a long arguement and much swearing) and we only compile it as
> a static library that isn't installed.  If someone wants a libsigc++
> library on their system then they should get the real thing.

I do not really see why you are doing this. At present it would be better to not
mess with libsigc++, i.e. use that thing out of the box, since that's what it was
made for. If, at a later point this would become a real issue I am sure a solution
can and will be found. But maybe I am misunderstanding what you were actually
doing.

> All the work on this is being done in the "rae" branch of lyx-devel.
> I haven't committed it yet but I do have libsigc++ integrated on my
> machine at home.  I have started on building the gui-indep structure and
> currently have a new Popups and PopupBase (the abstract base class).

Ok, I switched the lyx-devel branch over to rae and I am trying to compile it as
we speak. I would strongly recommend not to drift too far away from the main devel
branch but you know that much better than I do since you already lost lots of your
work the last time.

> The first draft of libsigc++ integration uses a slightly modified version
> of the libsigc++ configure.in in the sigc++ directory.  Hmmm, does NT let
> you have a directory called "sigc++"?  What about OS/2?

NT has no problems with directory names.

> Perhaps, but I want to be sure it's good before making it mainstream.
> After all I expect the floodgates will open with heaps of people
> scrambling to force their favourite toolkit to be top-dog and convince us
> to completely ditch xforms and half the existing codebase.

At that point this will hopefully happen - yet I doubt it.

> As I said before I want to filter the popup work and am trying to get a
> base where we can have popups from different toolkits co-existing although
> I don't want to allow a new popup to replace a hardcoded one until the
> hardcoded one has been made gui-indep.  That sounds a bit conusing let me
> try that again: gui-indep popups from multiple toolkits will be supported
> but will only be visible once the existing xforms popup has been made
> gui-indep.

I agree 100%, this is a step by step process. I'll try to summarize what the
necessary steps are her emostly for my own understanding.
1. Take a popup, e.g. paragraphs, find the code in the exisiting code base that
creates, updates and deletes this dialog and create a form_paragraphs.[Ch] pair of
files, then move the existing code.
Compile and see whether is all still works.
2. Create a class form_paragraphs that inherits from Dialog (the base dialog
class, was PopupBase) and the class will the implement the appropriate actions to
be taken when the slots for create, show, hide, destroy and update are called.
3. The update method is the most important because right now it is tightly
integrated with the GUI stuff.
For example, I tried to follow the current path through the code when the
paragraphs dialog is shown and found that this is essentially handled in lyx_cb.C
(like so many other things too :-).
>From MenuLayoutParagraph() first UpdateLayoutParagraph() is called. It looks like
that in the current view the text cursor knows the paragraph it is currently in
and that the paragraph has some properties that are shown in the dialog and can be
changed. This isnt a very clean design but it obviously works.
I heard somewhere that lyxfunc is the solution to all problems (just like 42) and
it could/should be asked here. Currently lyxfunc() doesnt have the fuctionality
for that or does it? What role would it play here?

So with this three steps one dialog is encapsulated. The slots can be called from
the meno or my means of the cursor moving to a new paragraph.


> > > A popup retrieves the data it needs from the kernel.  Andre described this
> > > as a Pull method a few months ago.  In fact one is his emails is on my
> > > list for inclusion in the docs.

Hmm, I missed that email, right now the dialog need direct access to the kernel
but that doesn seem bad to me.

> Oh and the popup will get its info from a LyXFunc.  We used to use a
> separate class called Communicator but I've since decided that was a dumb
> idea as a LyXFunc will be available to scripts and the outside world via
> the LyXServer.

Hmm so programs incorporating the LyXServer will have full access to all
lyxparagraph data?

> Yes,  I've since changed my mind and we'll just use the libsigc++ notation
> and forget the whole gtk--sig thing.

Good

> Gosh! You wrote PopupBase and called it Popup!!  Yes, you get the idea!

> MFC sounds good.  Qt costs money on Windows.  MFC is everywhere and it is
> _the_ native toolkit after all.  Besides Asger has said he's interested in
> doing/helping an MFC port as has someone in Sweden(?) who's willing to pay
> people to work on it!  Might be a short-term job in it for someone.

We may take this one to SourcForge or SourceXChange.

> I'm seriously considering suspending my enrolment for 6 months.  I'm
> working part-time and haven't really done anything constructive
> thesis-wise (or otherwise) for at least the last 6 months.  The last
> subtopic of my thesis crashed and burned so I've lost a lot of interest in
> working on it.  Besides it seems half the world is waiting for me to get
> this gui-indep stuff back on the rails.  May as well work on something
> that brings some joy and satisfaction and then reassess my thesis in a few
> months.

<OffTopic>
As someone who is in academics for most of his life I would strongly discourage
you from interrupting your theis. I dont know you personally but I do not think
you should interrupt because I have reason to suspect that  you never will
restart. You get the chance to get a Ph-D. once in your life, once you get older
it wont come back. Believe me, I know many people that utterly regret the step of
interrupting.
If you have lost all interest in the subject of your thesis you must go and talk
to your advisor about this. That's what he is there for. Talk to people about this
step, do not just simply let it creep up on you.
What do you want to do in life? What did you want to do when you started the
thesis? What happend that changed your mind.
The germans have a saying: It is better to end with fear than to fear without end.
So end this thesis if you can. Then checkout SourceForge whether you can get payed
for LyX work. I would assume that with appropriate advertisement you could find
someone to sponsor you for a year, but running your own show  isnt easy either.

If otoh you are kind of overly tempted to work on LyX I propose the following.
Use a computer that is not connected to the network, doesnt have email, no
webbrowser no modem fro your main work.
No excuses allowed - this has worked ten years ago it will work now.
Remove the LyX source code from it, better remove the compiler from it. Focus on
your work, do this for at first
four to siz hours a day - then treat yourself to something fun.
Read your email - hack LyX - fine. But limit your time. Never spent more time on
LyX then on your thesis.
It is not worth it.
<OffTopic/>


>
>
> Allan. (ARRae)

Reply via email to