Re: Startup problems

From: Dmitry Karasik <dmitry_at_karasik.eu.org>
Date: 26 Mar 2003 11:53:56 +0100
To: prima_at_prima.eu.org

On 25 Mar 03 at 23:27, "Norbert" (Norbert Schmidt) wrote:

 Norbert> Hello, I just discovered Prima and tried to install it. With my
 Norbert> old Perl (5.6.0, build 61x) it wouldn't work, so I installed the
 Norbert> latest AS-Binary (5.8.0 - build 805) and the fitting Prima (for
 Norbert> build 804). Im running Win98 SE.

Hello,

It seems the problems are due to incorrect determination of
Win98/SE version - at least this is my guess. Prima code believes it's NT,
and calls NT-specific functions ( not to freak out, but because they
are more precise and win95 analogs are morbid ).

You can check if it's true by inserting the following string
in your code right after 'use Prima' statement:
  
  Prima::Application-> sys_action('win32.SetVersion 98');

or, probably, '95' . If that works, I will investigate MS docs
about GetVersion() result on WIN98/SE. In any case, if
I'll come with a patch, you will need to recompile Prima,
so prepare the VC.

If you already have VC installed, tell me what does the
following code print out on your machine:

-----------------------------------------------
#include <stdio.h>
#include <windows.h>

void main( int argv, char * argc)
{
   OSVERSIONINFO os = { sizeof( OSVERSIONINFO)};
   DWORD version;
   version = GetVersion();
   GetVersionEx( &os);

#define IS_NT (BOOL)( version < 0x80000000)
#define IS_WIN32S (BOOL)(!(IS_NT) && (LOBYTE(LOWORD( version))<4))
#define IS_WIN95 (BOOL)(!(IS_NT) && !(IS_WIN32S))

   if ( IS_NT) {
      printf( "Windows NT\n");
   } else if ( IS_WIN95) {
      if ((os.dwPlatformId == VER_PLATFORM_WIN32_WINDOWS) &&
          ((os.dwMajorVersion > 4) ||
           ((os.dwMajorVersion == 4) && (os.dwMinorVersion > 0))))
         printf( "Windows 98\n");
      else
         printf( "Windows 95\n");
   } else
      printf( "Windows\n");
   printf("GetVersion:%x\nGetVersionEx:PlatformId:%d,Major:%d,Minor:%d\n",
          version, os.dwPlatformId, os.dwMajorVersion, os.dwMinorVersion);
}
--------------------------------------------------------

 Norbert> I guess, maybe if I did a complete recompilation of Perl and
 Norbert> Prima, it might work. But while I wouldn't think twice doing it
 Norbert> for Linux, I'm rather reluctant to trust VC6 to get everything
 Norbert> right ...

I myself hardly managed to get lot of things compiled properly on win9x.
If you'll have troubles compiling, I can get you a custom build.

 Norbert> I've been looking for a program editor/IDE that I could customize
 Norbert> excessively and easily using Perl. I had a look at "vim" and my
 Norbert> childhood trauma "vi" came back to me. (X)Emacs would be more to
 Norbert> my taste, if it weren't for that <censored> Lisp. Besides, there
 Norbert> are a few little things where I would like to mess with its
 Norbert> behavoir that would really require lots of work in (*shudder*)
 Norbert> Lisp or (maybe even worse;-)) patches to the source. And I want
 Norbert> it for Windows and Linux. Then I found Prima on CPAN and loved
 Norbert> the design from the start.

Prima::Edit is not something you compare to Emacs or Vim :) It's been
designed four years ago, with the idea to make something that would
suffice as a simplest possible multiline editor. Although it has nice
things like syntax highlighting or vertical blocks, in general it
needs some more polishing before it can pose as a coder's tool.

 Norbert> So, now I'll have a detailed look at Prima::Edit and - if I find
 Norbert> enough time - I may use it a base for a program editor that fits
 Norbert> my whims. Of course, I'll do it so that others can use it too.

That is a great idea. The one thing that screams out is lack of undo
feature there. Since implementing this requires changes in internal
data layout, I do not know if it is better to start a new, powerful
editor widget, or work on Prima::Edit until it shines.

-- 
Sincerely,
	Dmitry
--- www.karasik.eu.org ---
Life ain't fair, but the root password helps.
                      - BOFH
Received on Wed 26 Mar 2003 - 11:54:03 CET

This archive was generated by hypermail 2.2.0 : Sat 19 Mar 2011 - 18:35:04 CET