Re: Building pencil lib
by John-Mark Bell
On Mon, 24 Nov 2008, Michael Gerbracht wrote:
> I have a small follow up question: In principle I got pencil to work now.
> I would like to get rid of the text output when a draw file is produced.
> In pencil_build I found a collection of printf statements which are easy
> to comment out. I still get three lines:
>
> rufl_init.c rufl_init 130: new font manager
> rufl_init.c rufl_init 146: 32 faces, 12 families
> rufl_init.c rufl_load_cache 1043: 32 charsets loaded
>
> Inside rufl I cannot find the print statements, can you tell me where this
> text is output?
Lines 130, 146, and 1043 of rufl_init.c :)
I expect they use the LOG() macro.
If you build RUfl with debug turned off (add -DNDEBUG to CFLAGS in the
Makefile), then they should be silenced.
As for Pencil, the only time it will print anything out is if you call
pencil_dump().
John.
14 years, 9 months
Re: Netsurf / wrong hotkey defined for Fullscreen
by John-Mark Bell
On Thu, 27 Nov 2008, Horvath Andras wrote:
> I ran into a tiny cosmetic mistake in netsurf browser. The hotkey for
> Fullscreen is marked to be Ctrl+F11 though it works with Alt+F11.
>
> System: Debian Testing/Lenny 5.0 amd64
> Netsurf version: 1.2 (22 Mar 2008)
It's plain F11 in the current development version, and marked as such in
the appropriate menu. Therefore, this is fixed already :)
Thanks for the report,
John.
14 years, 9 months
Netsurf / wrong hotkey defined for Fullscreen
by Horvath Andras
Dear Developers,
I ran into a tiny cosmetic mistake in netsurf browser. The hotkey for
Fullscreen is marked to be Ctrl+F11 though it works with Alt+F11.
System: Debian Testing/Lenny 5.0 amd64
Netsurf version: 1.2 (22 Mar 2008)
Netsurf is Great! Thanks for your great work.
Regards,
Andras Horvath
hungary
http://log69.com
han(a)log69.com
14 years, 9 months
Javascript
by Hubert Maier
Hi there,
just a question from a lurker (and user of the new AmigaOS4 build)
I know that the work on implementing a JS engine has just about started by adding
DOM's (if i'm correct that is). My question is, will you be writing your own JS
engine or use an existing one (i.e. SpiderMonkey) and go from there?
Just curious, thank you :-)
@chris
When can we expect a new AmigaOS4 build?
Hav i already told you that i'd love to betatest? ;-)
Thanks to you too
Keep on guys, great browser
Ciao
Hubert
14 years, 10 months
Building pencil lib
by Michael Gerbracht
I have a small follow up question: In principle I got pencil to work now.
I would like to get rid of the text output when a draw file is produced.
In pencil_build I found a collection of printf statements which are easy
to comment out. I still get three lines:
rufl_init.c rufl_init 130: new font manager
rufl_init.c rufl_init 146: 32 faces, 12 families
rufl_init.c rufl_load_cache 1043: 32 charsets loaded
Inside rufl I cannot find the print statements, can you tell me where this
text is output?
Thank you very much,
Michael
14 years, 10 months
Editing in text fields
by Chris Young
I'm getting these quite often when attempting to select text in text
fields:
assertion "s->root->gadget->caret_text_box != NULL" failed: file "desktop/selection.c", line 737
On some (very few, found one earlier today but have forgotten now
what it was) sites the highlighting works perfectly, allowing me to
edit, highlighting didn't drift off into text that wasn't in the box
etc.
However, on the majority of sites I encounter, highlighting in a text
box appears to select nothing (you get the inverse video block but no
text where the text was - text outside the text box however gets
selected properly), pressing delete deletes the text that you think is
selected. Sometimes when selecting, the assertion above appears.
It appears to be that NetSurf is getting confused as to which box it
is supposed to be doing the text selection in. This is backed up by
the fact when I didn't get the problem, it was on a very simple site,
whereas on forums (such as vBulletin based ones where this always
happens) you get tables within tables with text fields in them.
I had a quick go at writing a test case, but it appears that just
nesting table and textareas isn't enough to exhibit the problem.
As far as I can tell, the RISC OS version of NetSurf replaces the text
fields with proper text editing gadgets, so this bug won't show up
there. The other ports should be able to reproduce it though.
Chris
14 years, 10 months
Re: Building pencil lib
by Michael Gerbracht
On 11 Nov, John-Mark Bell <jmb(a)netsurf-browser.org> wrote:
> On Tue, 11 Nov 2008, Michael Gerbracht wrote:
> > added "c" and "h" directories, copied the files into it and removed
> > the /c and /h ending
> If you checked the sources out using SVN, then this should have been
> done automatically.
Ok, that's good to know for the next time. In this case there were only a
few files so it was ok.
> > - trying to compile with: "gcc pencil_build.c -o penciltest"
> This won't work, as you've discovered. You're only building one of the
> library source files here. pencil_test.c is the source file for the test
> binary.
Yes, "penciltest" was probably a confusing name. I expected that
pencil_build will be compiled and saved as a file called penciltest. I did
not confuse it with pencil_test. But I was not aware that you have to use
two source files together to build one library file. (You do not have to
explain. If I use C more often then I am sure I can read this in every C
book).
> Something like: [...]
> will give you the library.
> And: [...]
> will give you the test binary.
With your help I was able to build both the library and test binary
without problems and ended up with a draw file. So for me my problem is
solved now!
Thank you very much!
Michael
14 years, 10 months
Re: Building pencil lib
by John-Mark Bell
On Tue, 11 Nov 2008, Michael Gerbracht wrote:
> What I did:
> - Download the source code of the library
> - Installed gcc and tested it with the "hello world" example - it compiled
> - I made a new directory, set it as work directory
> - added "c" and "h" directories, copied the files into it and removed the
> /c and /h ending
If you checked the sources out using SVN, then this should have been done
automatically.
> - trying to compile with: "gcc pencil_build.c -o penciltest"
This won't work, as you've discovered. You're only building one of the
library source files here. pencil_test.c is the source file for the test
binary.
Something like:
gcc -std=c99 -I<NSLibs$Dir>/include -c pencil_build.c -o pencil_build.o
gcc -std=c99 -I<NSLibs$Dir>/include -c pencil_save.c -o pencil_save.o
ar -cr libpencil.a pencil_build.o pencil_save.o
will give you the library.
And:
gcc -std=c99 -I<NSLibs$Dir>/include -L<NSLibs$Dir>/lib -lOSLib32 -lrufl -o
pencil_test pencil_test.c libpencil.a
will give you the test binary.
Alternatively, there's a pre-built libpencil in NSTools.
John.
14 years, 10 months
Building pencil lib
by Michael Gerbracht
I would like to use the pencil library in my own project. Unfortunately I
do not know how to comile it as I do not have experience with C
programming (I know a few things but never compiled anything major by
myself). I saw that there is a makefile included but this seems to be for
GCC SDK on unix like systems. But I hope that I can compile it using gcc
on RISC OS
What I did:
- Download the source code of the library
- Installed gcc and tested it with the "hello world" example - it compiled
- I made a new directory, set it as work directory
- added "c" and "h" directories, copied the files into it and removed the
/c and /h ending
- trying to compile with: "gcc pencil_build.c -o penciltest"
- got error messages about missing files, solved that by:
- adding the oslib directory from !NSTools
- adding missing "types" file from downloaded OSLib archive
- changed os file: "oslib/types.h" --> "types.h"
- changed os file: "oslib/oscore32.h" --> "oscore.h"
I think that it is not a good idea to changes the files of the library but
from the error messages I got gcc was unable to find the files. After
changing them the files were found. But now I am stuck with it at the
following point:
*gcc pencil_build.c -o penciltest
pencil_build.c: In function `pencil_free_item':
pencil_build.c:214: error: 'for' loop initial declaration used outside C99
mode
pencil_build.c: In function `pencil_dump_item':
pencil_build.c:234: error: 'for' loop initial declaration used outside C99
mode
pencil_build.c:250: error: 'for' loop initial declaration used outside C99
mode
pencil_build.c:269: error: 'for' loop initial declaration used outside C99
mode
Would be very nice if somebody could help me. If this is only the tip of
the iceberg of problems and somebody has a compiled version of the library
this is also fine for me.
Thank you very much,
Michael Gerbracht
14 years, 10 months
Re: Frames using CSS?
by John-Mark Bell
On Sun, 9 Nov 2008, Chris Young wrote:
> The frames support in my port is a bit dodgy. I was toying with some
> implementation ideas so frames display correctly, but I don't have any
> easy way of doing it without writing my own balance group virtual
> gadget class.
>
> Anyway, I stumbled across this: http://www.tvtv.co.uk
>
> It looks like it has frames, but it doesn't - the frame is created
> using CSS. The vertical scroll bars don't work either, but that's an
> aside :)
>
> Is there any way of persuading NetSurf to create frames like this
> instead of "real" frames? Or at least for IFrames?
Nope. Frames and iframes are handled specially in the core code.
J.
14 years, 10 months