POV-Ray : Newsgroups : povray.beta-test : 2.2.1.2 Comments (block comments). : Re: 2.2.1.2 Comments (block comments). Server Time
29 Jul 2024 06:16:58 EDT (-0400)
  Re: 2.2.1.2 Comments (block comments).  
From: Warp
Date: 26 Mar 2006 04:05:07
Message: <44265942@news.povray.org>
Lance Birch <-> wrote:
> I don't have any idea how the editor currently does its syntax highlighting, so
> I don't know what's involved in implementing this - I assume it mustn't be as
> easy as I thought it would be if it hasn't been done already.

  The explanation may be as simple as:
  The editor code has been made by someone else, and trying to figure out
from someone else's code exactly where the comment-coloring code is and
how it works and how it should be modified is too much trouble taking into
account the enormous amount of more important other work yet to be done.

  Trying to figure out someone else's code is often a rather appalling
prospect. I know this from personal experience. :)

  For example, I once, many years ago, tried to compile mplayer for
Sparc/Solaris. At that time the support for that platform was not very good,
but after some tweaking I got it compiled and running. The only problem
was that the program made a check that the target architecture byte
endianess was not supported (ultrasparc is a high-endian processor, unlike
intels, which are low-endian) and refused to continue.
  Well, I located the check (it was easy to find by just searching the
error message and then the place where it was being used) and removed it.
  Presto, the video started showing. The only problem was that the red and
blue channels were swapped.
  In the end, the solution was rather simple: It was enough to swap the
indexing values in two lines of code in one file (I used #ifdefs for better
compatibility). However, it took me over an hour to actually locate those
two lines. mplayer is such an enormously complex program that it was
really hard to try to figure out its inner workings.

  Locating and understanding the syntax-coloring code in the winpov
editor is probably not this hard, but given that there are more urgent
issues at hand, it's probably a quite low-priority task.

-- 
                                                          - Warp


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.