Daniel Leidert | 1 Oct 2008 17:04
Picon

Re: optional sections in XML? any xml experts?

Am Freitag, den 26.09.2008, 17:36 +0200 schrieb Olivier Sessink:
> Hi all,
> 
> the new editor widget is capable of handling syntax highlighting and
> code-completion for thousands of tag-names and attributes (html and xml)
> or function-names (C, PHP, GTK).
> 
> However: this will use more memory.
> 
> Some users might want to have all PHP functions in the PHP patterns.
> Others (I do!) want to have all gtk functions in the C patterns.
> 
> What I would like to do is to make this optional: a user can decide to
> have a very small C language pattern, or one with all GTK functions, or
> anything else.
> 
> But what is an appropriate XML representation for such optional
> sections?

A class attribute?

> And is there XML technology (XSLT?) that might help to
> automatically remove the unwanted sections?

XPath I guess, if you use classes. I don't think, you need XSLT to
transform the XML file first.

> I'm not really a XML expert, so any advice is welcome.

HTH and regards, Daniel
(Continue reading)

Olivier Sessink | 2 Oct 2008 15:10
Picon
Gravatar

running the experimental widget with 4500 patterns

Hi all,

preliminary language files parsing now works (multi-threaded!), so I
created a php language file with over 4500 patterns. This creates a
scanning table of 7Mb, but performance is excellent!

regards,
	Olivier
Olivier Sessink | 4 Oct 2008 21:17
Picon
Gravatar

Re: optional sections in XML? any xml experts?

Daniel Leidert wrote:
> Am Freitag, den 26.09.2008, 17:36 +0200 schrieb Olivier Sessink:
>> What I would like to do is to make this optional: a user can decide to
>> have a very small C language pattern, or one with all GTK functions, or
>> anything else.
>>
>> But what is an appropriate XML representation for such optional
>> sections?
> 
> A class attribute?

done that. however, I'm not using Xpath but I just check the value of
the class attribute when deciding whether or not to add the pattern to
the scanning tables.

regards,
	Olivier

Olivier Sessink | 5 Oct 2008 23:19
Picon
Gravatar

test the new editor widget

Hi all

at
http://bluefish.openoffice.nl/temp/bftestview2.tar.gz
you can download the new editor widget. It is mostly finished now.

Unpack, run make (you need gtk and libxml headers installed), and start with

./testapp /path/to/test.file

I've provided sample language files for php, C, html, and generix XML.

To see some of the features:

in a php file:
- all known functions should be highlighted within <?php ?>
- autocomplete any function
- try to autocomplete mysql_query to see extended autocompletion

in an html file:
- try to add <meta> to <body> --> does not highlight
- try to add <div> to <head> --> does not highlight
- try to autocomplete <img (within <body>)

please let me know what you think.

regards,
	Olivier
alex bodnaru | 6 Oct 2008 02:10
Picon
Gravatar

Re: test the new editor widget


hi olivier,

the widget seems very nice.

it even makes me try to make an asp bflang.

please note, that the first <?php ... ?> block in the file won't fold.

hope that helps,
alex

Olivier Sessink wrote:
> Hi all
> 
> at
> http://bluefish.openoffice.nl/temp/bftestview2.tar.gz
> you can download the new editor widget. It is mostly finished now.
> 
> Unpack, run make (you need gtk and libxml headers installed), and start with
> 
> ./testapp /path/to/test.file
> 
> I've provided sample language files for php, C, html, and generix XML.
> 
> To see some of the features:
> 
> in a php file:
> - all known functions should be highlighted within <?php ?>
> - autocomplete any function
(Continue reading)

clansco | 6 Oct 2008 11:51
Favicon

slackware

Hello,
GIO is part of GLib 2.16.0 and above,
glib2-2.16 is  only provided by slackware current,
so it's time to upgrade to current !

Regards,
ff
Olivier Sessink | 6 Oct 2008 17:58
Picon
Gravatar

Re: test the new editor widget

alex bodnaru wrote:
> 
> hi olivier,
> 
> the widget seems very nice.
> 
> it even makes me try to make an asp bflang.
> 
> please note, that the first <?php ... ?> block in the file won't fold.

thanks, fixed that.

regards,
	Olivier
Olivier Sessink | 6 Oct 2008 22:04
Picon
Gravatar

Re: File save problem

Thanos Chatziathanassiou wrote:

> (apologies for the late reply, but my mailer had a mind of its own, it
> seems)
> 
> Sure...it's still messy, but only because the problems run a little deeper:
> - make_backup option in g_file_replace_contents(_async)() always created
> a file ``file~'' backup, which isn't necessarily what the user selected
> - if make_backup isn't TRUE, the whole thing doesn't work and I at least
> can't tell why. So we're forced to create an backup file even if the
> user doesn't want one or has selected it to be saved in another form (ie
> not ``file~'') and then unlink it if we must.
> - backup_uri_from_orig_uri() had also ``~'' hardcoded as a backup
> suffix. I took the liberty to modify it.
>> Olivier
>>
>> b.t.w.: is g_file_replace_contents_async the buggy function, or did you
>> not try with the _async function?
>>   
> no, g_file_replace_contents_async works fine - at least as good as plain
> g_file_replace_contents, but if I call it twice (eg because the first
> try didn't work on my smbnetfs), bluefish complains that the file was
> modified by another process. So I only use plain g_file_replace_contents
> when we know that the first g_file_replace_contents_async failed. Its
> effect on normal working mounts should be almost nonexistent - I still
> use g_file_query_info to find out if it worked or not.
> 
> Let me know if I can offer any assistance.
> 
> Best Regards,
(Continue reading)

Olivier Sessink | 9 Oct 2008 12:20
Picon
Gravatar

Re: test the new editor widget

alex bodnaru wrote:

> it even makes me try to make an asp bflang.

do you have enough information how to create a asp language file?

Olivier
Thanos Chatziathanassiou | 9 Oct 2008 12:26
Favicon

Re: test the new editor widget

O/H Olivier Sessink έγραψε:
> alex bodnaru wrote:
>
>   
>> it even makes me try to make an asp bflang.
>>     
>
> do you have enough information how to create a asp language file?
>   
I have something that works quite like I'd expect for asp/perl 
(PerlScript on IIS, or apache+mod_perl+Apache::ASP)
See if you can pull anything useful out of it.

Regards,
Thanos Chatziathanassiou

Attachment (asp-perl.bflang): text/xml, 3976 bytes
Attachment (smime.p7s): application/x-pkcs7-signature, 3237 bytes

Gmane