Re: [GNC] I just need a line feed
Op donderdag 7 februari 2019 23:15:18 CET schreef David Carlson: > I am faced with inserting linefeeds into OFX files at certain critical > locations to make them more palatable to libofx. In that context I have > found that I can open them with LibreOffice, turn on Formatting Marks (Ctrl > F10) then place the curser wherever I want a linefeed and press > Shift-Enter. Last, I need to be sure to save the file with a modified > filename but the original suffix in text-only format. > > That is working for me. Of course the linefeeds do need to be correctly > placed for the application. That's a completely different story :) The OFX parser is not an html parser, though both are based on SGML in one way or another. And the OFX parser has a bug causing it to misinterpret certain tags. By sheer luck the bug is not triggered if that tag is on a line of its own. However the html parser has no bug. Html be definition ignores newlines in textual data. The "\n" people refer to here is just a coder's representation of that newline. So the html parser will ignore it. In this case Derek offered the proper solution: use instead. Regards, Geert ___ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. - Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.
Re: [GNC] I just need a line feed
Thank you for the prompt reply! It worked! After a couple of failed tries, I found that it works if the is inserted inside of the closing quotes: (string-append "%s %s " Much appreciated. At 01:45 PM Thursday, Derek Atkins wrote: Content-Transfer-Encoding: 8bit Hi, On Thu, February 7, 2019 3:34 pm, Richard Marmor wrote: [snip] >(gnc:html-document-set-title! > doc (sprintf #f > (string-append "%s %s " <-- add here > (_ "For Period Covering %s to %s")) > company-name report-title > (gnc-print-date start-date-printable) > (gnc-print-date end-date-tp))) >Can someone please tell me how to modify that to insert a line feed >so the report title will appear on two lines as: > [Company Name][Report Title] >For Period Covering [start date] to [end date] >I am not a programmer. I tried reading some of the help information >among the SCM files, but frankly it was all Greek to me. Help would >be appreciated. Have you tried adding at the end of the "%s %s" above? >Thank you! > Please remember to CC this list on all your replies. > You can do this by using Reply-To-List or Reply-All. -derek -- Derek Atkins 617-623-3745 de...@ihtfp.com [1]www.ihtfp.com Computer and Internet Security Consultant References 1. http://www.ihtfp.com/ ___ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. - Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.
Re: [GNC] I just need a line feed
I am faced with inserting linefeeds into OFX files at certain critical locations to make them more palatable to libofx. In that context I have found that I can open them with LibreOffice, turn on Formatting Marks (Ctrl F10) then place the curser wherever I want a linefeed and press Shift-Enter. Last, I need to be sure to save the file with a modified filename but the original suffix in text-only format. That is working for me. Of course the linefeeds do need to be correctly placed for the application. David Carlson On Thu, Feb 7, 2019 at 3:06 PM Derek Atkins wrote: > Hi, > > On Thu, February 7, 2019 3:51 pm, Stephen M. Butler wrote: > > > > I'm slowly learning Scheme. I general a is a decimal 10 or 0x0A in > > the ASCII collating sequence. In the Nix world you can use an \n to > > represent it. > > This wont help because it's being parsed by an HTML parser. > > > Try changing: "For Period Covering %s to %s" > > > >To: "\nFor Period Covering %s to %s" > > This will break the translation. You don't want to modify a (_ ...) > string. > > > Please remember to CC this list on all your replies. > > You can do this by using Reply-To-List or Reply-All. > > -derek > > -- >Derek Atkins 617-623-3745 >de...@ihtfp.com www.ihtfp.com >Computer and Internet Security Consultant > > ___ > gnucash-user mailing list > gnucash-user@gnucash.org > To update your subscription preferences or to unsubscribe: > https://lists.gnucash.org/mailman/listinfo/gnucash-user > If you are using Nabble or Gmane, please see > https://wiki.gnucash.org/wiki/Mailing_Lists for more information. > - > Please remember to CC this list on all your replies. > You can do this by using Reply-To-List or Reply-All. > ___ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. - Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.
Re: [GNC] I just need a line feed
Hi, On Thu, February 7, 2019 3:51 pm, Stephen M. Butler wrote: > > I'm slowly learning Scheme. I general a is a decimal 10 or 0x0A in > the ASCII collating sequence. In the Nix world you can use an \n to > represent it. This wont help because it's being parsed by an HTML parser. > Try changing: "For Period Covering %s to %s" > > To: "\nFor Period Covering %s to %s" This will break the translation. You don't want to modify a (_ ...) string. > Please remember to CC this list on all your replies. > You can do this by using Reply-To-List or Reply-All. -derek -- Derek Atkins 617-623-3745 de...@ihtfp.com www.ihtfp.com Computer and Internet Security Consultant ___ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. - Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.
Re: [GNC] I just need a line feed
Hi, On Thu, February 7, 2019 3:47 pm, Steve Cohen wrote: > I'm not a developer of gnucash so take this with a grain of salt, but > putting a '\n' where you want the line feed might work. If you're on > windows, you might need to do '\n\r'. Try it, maybe it's a help to you, > but no guarantees. Nope, that's very unlikely to do what you want, because it's processed by an HTML parser and \n means nothing to that. > Please remember to CC this list on all your replies. > You can do this by using Reply-To-List or Reply-All. -derek -- Derek Atkins 617-623-3745 de...@ihtfp.com www.ihtfp.com Computer and Internet Security Consultant ___ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. - Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.
Re: [GNC] I just need a line feed
On 2/7/19 12:34 PM, Richard Marmor wrote: >On 1/27 I posted the request for help below to which there have been >no replies. Is there no one out there who understands .SCM files? >Help . . . >--- >-- >In Gnucash 2.6.21, the standard report title for an Income Statement >appears as: >[Company Name][Report Title] For Period Covering [start date] to [end >date] >all on one long line, which for my purposes is too lengthy. >In the report's generator file, income-statement.scm, I found this: >(gnc:html-document-set-title! > doc (sprintf #f > (string-append "%s %s " > (_ "For Period Covering %s to %s")) > company-name report-title > (gnc-print-date start-date-printable) > (gnc-print-date end-date-tp))) >Can someone please tell me how to modify that to insert a line feed >so the report title will appear on two lines as: > [Company Name][Report Title] >For Period Covering [start date] to [end date] >I am not a programmer. I tried reading some of the help information >among the SCM files, but frankly it was all Greek to me. Help would >be appreciated. >Thank you! > _ I'm slowly learning Scheme. I general a is a decimal 10 or 0x0A in the ASCII collating sequence. In the Nix world you can use an \n to represent it. Try changing: "For Period Covering %s to %s" To: "\nFor Period Covering %s to %s" Or do a search for "linefeed in Scheme". Scheme may need a way for you to escape the escape sequence. Don't know. -- Stephen M Butler, PMP, PSM stephen.m.butle...@gmail.com kg...@arrl.net 253-350-0166 --- GnuPG Fingerprint: 8A25 9726 D439 758D D846 E5D4 282A 5477 0385 81D8 ___ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. - Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.
Re: [GNC] I just need a line feed
I'm not a developer of gnucash so take this with a grain of salt, but putting a '\n' where you want the line feed might work. If you're on windows, you might need to do '\n\r'. Try it, maybe it's a help to you, but no guarantees. On 2/7/19 2:34 PM, Richard Marmor wrote: On 1/27 I posted the request for help below to which there have been no replies. Is there no one out there who understands .SCM files? Help . . . --- -- In Gnucash 2.6.21, the standard report title for an Income Statement appears as: [Company Name][Report Title] For Period Covering [start date] to [end date] all on one long line, which for my purposes is too lengthy. In the report's generator file, income-statement.scm, I found this: (gnc:html-document-set-title! doc (sprintf #f (string-append "%s %s " (_ "For Period Covering %s to %s")) company-name report-title (gnc-print-date start-date-printable) (gnc-print-date end-date-tp))) Can someone please tell me how to modify that to insert a line feed so the report title will appear on two lines as: [Company Name][Report Title] For Period Covering [start date] to [end date] I am not a programmer. I tried reading some of the help information among the SCM files, but frankly it was all Greek to me. Help would be appreciated. Thank you! ___ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. - Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All. ___ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. - Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.
Re: [GNC] I just need a line feed
Hi, On Thu, February 7, 2019 3:34 pm, Richard Marmor wrote: [snip] >(gnc:html-document-set-title! > doc (sprintf #f > (string-append "%s %s " <-- add here > (_ "For Period Covering %s to %s")) > company-name report-title > (gnc-print-date start-date-printable) > (gnc-print-date end-date-tp))) >Can someone please tell me how to modify that to insert a line feed >so the report title will appear on two lines as: > [Company Name][Report Title] >For Period Covering [start date] to [end date] >I am not a programmer. I tried reading some of the help information >among the SCM files, but frankly it was all Greek to me. Help would >be appreciated. Have you tried adding at the end of the "%s %s" above? >Thank you! > Please remember to CC this list on all your replies. > You can do this by using Reply-To-List or Reply-All. -derek -- Derek Atkins 617-623-3745 de...@ihtfp.com www.ihtfp.com Computer and Internet Security Consultant ___ gnucash-user mailing list gnucash-user@gnucash.org To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. - Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.