Editor format adjustments

Wednesday, 19 February 2025 · 6 messages · last reply 24 Feb 2025
JK
Joel Kalvesmaki19 Feb 2025 04:05 #
Hi everyone, I just joined. BaseX is awesome (as y'all know). I like CTRL+SHIFT+F for formatting, but it is also messing up string values, which especially wreaks havoc with regular expressions. That is...
    let $regex := "(a|z)"
...becomes...
    let $regex := "(
       a|z
    )"
I didn't see anything in the documentation or archives about micromanaging the formatting. Is the best practice to avoid formatting altogether? Or is there a hidden pragma to exempt lines from being formatted? Joel
-- Joel Kalvesmaki Director, Text Alignment Network http://textalign.net
AB
Andy Bunce19 Feb 2025 13:34 #
Hi Joel, Welcome. I never use the GUI format option because it is very aggressive with parenthesis regardless of the context. E.g. let $num := abs($d) becomes: let $num := abs( $d ) But obviously it should not be messing with strings. I am not aware of any workarounds. /Andy
Quoted text · Joel Kalvesmaki · 27 lines
On Wed, 19 Feb 2025 at 03:05, Joel Kalvesmaki <director at textalign.net> wrote: > Hi everyone, I just joined. BaseX is awesome (as y'all know). > > I like CTRL+SHIFT+F for formatting, but it is also messing up string > values, which especially wreaks havoc with regular expressions. That > is... > > let $regex := "(a|z)" > > ...becomes... > > let $regex := "( > a|z > )" > > I didn't see anything in the documentation or archives about > micromanaging the formatting. Is the best practice to avoid formatting > altogether? Or is there a hidden pragma to exempt lines from being > formatted? > > Joel > -- > Joel Kalvesmaki > Director, Text Alignment Network > http://textalign.net >
CG
Christian Grün22 Feb 2025 12:34 #
Hi Joel, Our code formatting feature is very basic and straightforward. Indeed, we never planned to keep it in the GUI, but some people convinced us not to remove it. I’ve just improved the detection of strings and comments in the latest snapshot a little [1]; maybe that helps. Thanks for all, Christian [1] https://files.basex.org/releases/latest/
Quoted text · Andy Bunce · 44 lines
On Wed, Feb 19, 2025 at 1:35 PM Andy Bunce <bunce.andy at gmail.com> wrote: > Hi Joel, > > Welcome. I never use the GUI format option because it is very aggressive > with parenthesis regardless of the context. E.g. > let $num := abs($d) > becomes: > let $num := abs( > $d > ) > But obviously it should not be messing with strings. I am not aware of any > workarounds. > > /Andy > > On Wed, 19 Feb 2025 at 03:05, Joel Kalvesmaki <director at textalign.net> > wrote: > >> Hi everyone, I just joined. BaseX is awesome (as y'all know). >> >> I like CTRL+SHIFT+F for formatting, but it is also messing up string >> values, which especially wreaks havoc with regular expressions. That >> is... >> >> let $regex := "(a|z)" >> >> ...becomes... >> >> let $regex := "( >> a|z >> )" >> >> I didn't see anything in the documentation or archives about >> micromanaging the formatting. Is the best practice to avoid formatting >> altogether? Or is there a hidden pragma to exempt lines from being >> formatted? >> >> Joel >> -- >> Joel Kalvesmaki >> Director, Text Alignment Network >> http://textalign.net >> >
GS
Graydon Saunders23 Feb 2025 15:33 #
Last time I asked the oXygen folks about BaseX support they demurred, because they don't perceive sufficient demand. (I have an unreasonable belief that people would use it if it was there, but of course they're not going to use it before it's there.) Any chance of trying to talk them into it, one corporate entity to another? -- Graydon
Quoted text · Christian Grün · 56 lines
On Sat, Feb 22, 2025 at 6:40 AM Christian Grün <christian.gruen at gmail.com> wrote: > > Hi Joel, > > Our code formatting feature is very basic and straightforward. Indeed, we never planned to keep it in the GUI, but some people convinced us not to remove it. > > I’ve just improved the detection of strings and comments in the latest snapshot a little [1]; maybe that helps. > > Thanks for all, > Christian > > [1] https://files.basex.org/releases/latest/ > > > > On Wed, Feb 19, 2025 at 1:35 PM Andy Bunce <bunce.andy at gmail.com> wrote: >> >> Hi Joel, >> >> Welcome. I never use the GUI format option because it is very aggressive with parenthesis regardless of the context. E.g. >> let $num := abs($d) >> becomes: >> let $num := abs( >> $d >> ) >> But obviously it should not be messing with strings. I am not aware of any workarounds. >> >> /Andy >> >> On Wed, 19 Feb 2025 at 03:05, Joel Kalvesmaki <director at textalign.net> wrote: >>> >>> Hi everyone, I just joined. BaseX is awesome (as y'all know). >>> >>> I like CTRL+SHIFT+F for formatting, but it is also messing up string >>> values, which especially wreaks havoc with regular expressions. That >>> is... >>> >>> let $regex := "(a|z)" >>> >>> ...becomes... >>> >>> let $regex := "( >>> a|z >>> )" >>> >>> I didn't see anything in the documentation or archives about >>> micromanaging the formatting. Is the best practice to avoid formatting >>> altogether? Or is there a hidden pragma to exempt lines from being >>> formatted? >>> >>> Joel >>> -- >>> Joel Kalvesmaki >>> Director, Text Alignment Network >>> http://textalign.net
EK
Eliot Kimber24 Feb 2025 16:59 #
I have also bugged Radu about it but so far to no avail—I was just at the DITA Europe conference where Radu also was but I didn’t think to ask about this ☹ If someone had a bit of time it shouldn’t be too hard to gin up an add-on that that provides BaseX access but I definitely do not have that time at the moment. Cheers, E. _____________________________________________ Eliot Kimber Sr. Staff Content Engineer O: 512 554 9368 servicenow servicenow.com<https://www.servicenow.com> LinkedIn<https://www.linkedin.com/company/servicenow> | X<https://twitter.com/servicenow> | YouTube<https://www.youtube.com/user/servicenowinc> | Instagram<https://www.instagram.com/servicenow>
Quoted text · Graydon Saunders · 68 lines
From: Graydon Saunders <graydonish at gmail.com> Date: Monday, February 24, 2025 at 9:41 AM To: Christian Grün <christian.gruen at gmail.com> Cc: Joel Kalvesmaki <director at textalign.net>, basex-talk at mailman.uni-konstanz.de <basex-talk at mailman.uni-konstanz.de> Subject: [basex-talk] Re: Editor format adjustments [External Email] Last time I asked the oXygen folks about BaseX support they demurred, because they don't perceive sufficient demand. (I have an unreasonable belief that people would use it if it was there, but of course they're not going to use it before it's there.) Any chance of trying to talk them into it, one corporate entity to another? -- Graydon On Sat, Feb 22, 2025 at 6:40 AM Christian Grün <christian.gruen at gmail.com> wrote: > > Hi Joel, > > Our code formatting feature is very basic and straightforward. Indeed, we never planned to keep it in the GUI, but some people convinced us not to remove it. > > I’ve just improved the detection of strings and comments in the latest snapshot a little [1]; maybe that helps. > > Thanks for all, > Christian > > [1] https://files.basex.org/releases/latest/<https://files.basex.org/releases/latest> > > > > On Wed, Feb 19, 2025 at 1:35 PM Andy Bunce <bunce.andy at gmail.com> wrote: >> >> Hi Joel, >> >> Welcome. I never use the GUI format option because it is very aggressive with parenthesis regardless of the context. E.g. >> let $num := abs($d) >> becomes: >> let $num := abs( >> $d >> ) >> But obviously it should not be messing with strings. I am not aware of any workarounds. >> >> /Andy >> >> On Wed, 19 Feb 2025 at 03:05, Joel Kalvesmaki <director at textalign.net> wrote: >>> >>> Hi everyone, I just joined. BaseX is awesome (as y'all know). >>> >>> I like CTRL+SHIFT+F for formatting, but it is also messing up string >>> values, which especially wreaks havoc with regular expressions. That >>> is... >>> >>> let $regex := "(a|z)" >>> >>> ...becomes... >>> >>> let $regex := "( >>> a|z >>> )" >>> >>> I didn't see anything in the documentation or archives about >>> micromanaging the formatting. Is the best practice to avoid formatting >>> altogether? Or is there a hidden pragma to exempt lines from being >>> formatted? >>> >>> Joel >>> -- >>> Joel Kalvesmaki >>> Director, Text Alignment Network >>> http://textalign.net<http://textalign.net>
CG
Christian Grün24 Feb 2025 17:10 #
Thanks all, Keep on going. Oxygen integration is not one of our main priorities, and it has been quite a while ago that we talked to the Oxygen guys about possible solutions, but we will certainly be responsive if our APIs need to be improved to get it going. For a basic integration, I think most of you know our online documentation [1]. Best, Christian [1] https://docs.basex.org/main/Integrating_oXygen
Quoted text · Eliot Kimber · 125 lines
On Mon, Feb 24, 2025 at 4:59 PM Eliot Kimber <eliot.kimber at servicenow.com> wrote: > I have also bugged Radu about it but so far to no avail—I was just at the > DITA Europe conference where Radu also was but I didn’t think to ask about > this ☹ > > > > If someone had a bit of time it shouldn’t be too hard to gin up an add-on > that that provides BaseX access but I definitely do not have that time at > the moment. > > > > Cheers, > > > > E. > > _____________________________________________ > > *Eliot Kimber* > > Sr. Staff Content Engineer > > O: 512 554 9368 > > > > *servicenow* > > > > servicenow.com <https://www.servicenow.com> > > LinkedIn <https://www.linkedin.com/company/servicenow> | X > <https://twitter.com/servicenow> | YouTube > <https://www.youtube.com/user/servicenowinc> | Instagram > <https://www.instagram.com/servicenow> > > > > *From: *Graydon Saunders <graydonish at gmail.com> > *Date: *Monday, February 24, 2025 at 9:41 AM > *To: *Christian Grün <christian.gruen at gmail.com> > *Cc: *Joel Kalvesmaki <director at textalign.net>, > basex-talk at mailman.uni-konstanz.de <basex-talk at mailman.uni-konstanz.de> > *Subject: *[basex-talk] Re: Editor format adjustments > > [External Email] > > Last time I asked the oXygen folks about BaseX support they demurred, > because they don't perceive sufficient demand. > > (I have an unreasonable belief that people would use it if it was > there, but of course they're not going to use it before it's there.) > > Any chance of trying to talk them into it, one corporate entity to another? > > -- Graydon > > On Sat, Feb 22, 2025 at 6:40 AM Christian Grün > <christian.gruen at gmail.com> wrote: > > > > Hi Joel, > > > > Our code formatting feature is very basic and straightforward. Indeed, > we never planned to keep it in the GUI, but some people convinced us not to > remove it. > > > > I’ve just improved the detection of strings and comments in the latest > snapshot a little [1]; maybe that helps. > > > > Thanks for all, > > Christian > > > > [1] https://files.basex.org/releases/latest/ > > > > > > > > On Wed, Feb 19, 2025 at 1:35 PM Andy Bunce <bunce.andy at gmail.com> wrote: > >> > >> Hi Joel, > >> > >> Welcome. I never use the GUI format option because it is very > aggressive with parenthesis regardless of the context. E.g. > >> let $num := abs($d) > >> becomes: > >> let $num := abs( > >> $d > >> ) > >> But obviously it should not be messing with strings. I am not aware of > any workarounds. > >> > >> /Andy > >> > >> On Wed, 19 Feb 2025 at 03:05, Joel Kalvesmaki <director at textalign.net> > wrote: > >>> > >>> Hi everyone, I just joined. BaseX is awesome (as y'all know). > >>> > >>> I like CTRL+SHIFT+F for formatting, but it is also messing up string > >>> values, which especially wreaks havoc with regular expressions. That > >>> is... > >>> > >>> let $regex := "(a|z)" > >>> > >>> ...becomes... > >>> > >>> let $regex := "( > >>> a|z > >>> )" > >>> > >>> I didn't see anything in the documentation or archives about > >>> micromanaging the formatting. Is the best practice to avoid formatting > >>> altogether? Or is there a hidden pragma to exempt lines from being > >>> formatted? > >>> > >>> Joel > >>> -- > >>> Joel Kalvesmaki > >>> Director, Text Alignment Network > >>> http://textalign.net >

⚡Generated with XQuery