From gambas at ...1... Wed Mar 2 21:40:17 2016 From: gambas at ...1... (=?UTF-8?Q?Beno=c3=aet_Minisini?=) Date: Wed, 2 Mar 2016 21:40:17 +0100 Subject: [Gambas-devel] Change to gb.db.odbc to use ODBC Connection Strings. In-Reply-To: <56D03B19.2040102@...176...> References: <56D03B19.2040102@...176...> Message-ID: <56D74FB1.3020807@...1...> Le 26/02/2016 12:46, ML a ?crit : > Beno?t, > > Hi. I'm attaching a quick and dirty main.c module for ODBC. I made > the changes below to the latest revision in SVN. > > This module includes two new calls. One to get a proper record count > for statements (GetRecordCount()), and another for proper ODBC error > retrieval (reportODBCError()). I'm planning on adding the error > retrieval routine to most debug calls when I finally get to tidy the > module, so one can check what exactly went wrong with ODBC. > > GetRecordCount() basically gets to the last record, grabs its row > number and returns it as the row count. It tries not to alter the > current rowset position. If for any reason it cannot do it (for > example due to having a non-scrollable rowset), it will return the > usual -1 for backwards-compatibility with the original > SQLRowCount(). > > I tested it several times with two different MSSql servers at work > using different FreeTDS protocol versions and even over the internet, > and it seems to work. If you smell anything suspicious in it, just > say the word! > > Regards, zxMarce. > Hi, I have just merged your changes, changing some spaces in the code, and fixing the warning on 64 bits (SQLINTEGER is an int, so it requires "%d" in fprintf, not "%ld"). I think it would be better if you commit your changes directly in the subversion repository. Regards, -- Beno?t Minisini From d4t4full at ...176... Mon Mar 7 18:30:38 2016 From: d4t4full at ...176... (ML) Date: Mon, 7 Mar 2016 14:30:38 -0300 Subject: [Gambas-devel] Change to gb.db.odbc to use ODBC Connection Strings. In-Reply-To: <56D74FB1.3020807@...1...> References: <56D03B19.2040102@...176...> <56D74FB1.3020807@...1...> Message-ID: <56DDBABE.3040603@...176...> On 2016-03-02 17:40, Beno?t Minisini wrote: > Le 26/02/2016 12:46, ML a ?crit : >> Beno?t, >> Hi. I'm attaching a quick and dirty main.c module for ODBC. I made >> the changes below to the latest revision in SVN. >> This module includes two new calls. One to get a proper record count >> for statements (GetRecordCount()), and another for proper ODBC error >> retrieval (reportODBCError()). I'm planning on adding the error >> retrieval routine to most debug calls when I finally get to tidy the >> module, so one can check what exactly went wrong with ODBC. >> GetRecordCount() basically gets to the last record, grabs its row >> number and returns it as the row count. It tries not to alter the >> current rowset position. If for any reason it cannot do it (for >> example due to having a non-scrollable rowset), it will return the >> usual -1 for backwards-compatibility with the original >> SQLRowCount(). >> I tested it several times with two different MSSql servers at work >> using different FreeTDS protocol versions and even over the internet, >> and it seems to work. If you smell anything suspicious in it, just >> say the word! >> Regards, zxMarce. > Hi, > I have just merged your changes, changing some spaces in the code, and > fixing the warning on 64 bits (SQLINTEGER is an int, so it requires "%d" > in fprintf, not "%ld"). > I think it would be better if you commit your changes directly in the > subversion repository. > Regards, Beno?t, Wow, better late than never. Just saw your response. Thank you. Still remains the LIMIT handling and general code tidying. Thanks a lot also for the SVN direct commit offer, I'll give it a thought or two. I'll also get some info on SVN and how it works. Meanwhile, since I'm not a user of SVN, just in case I'll decline: Don't want to trash the whole of Gambas on a bad commit! Regards, zxMarce. From gambas at ...1... Mon Mar 7 18:39:23 2016 From: gambas at ...1... (=?UTF-8?Q?Beno=c3=aet_Minisini?=) Date: Mon, 7 Mar 2016 18:39:23 +0100 Subject: [Gambas-devel] Change to gb.db.odbc to use ODBC Connection Strings. In-Reply-To: <56DDBABE.3040603@...176...> References: <56D03B19.2040102@...176...> <56D74FB1.3020807@...1...> <56DDBABE.3040603@...176...> Message-ID: <56DDBCCB.1010207@...1...> Le 07/03/2016 18:30, ML a ?crit : > On 2016-03-02 17:40, Beno?t Minisini wrote: >> Le 26/02/2016 12:46, ML a ?crit : >>> Beno?t, >>> Hi. I'm attaching a quick and dirty main.c module for ODBC. I made >>> the changes below to the latest revision in SVN. >>> This module includes two new calls. One to get a proper record count >>> for statements (GetRecordCount()), and another for proper ODBC error >>> retrieval (reportODBCError()). I'm planning on adding the error >>> retrieval routine to most debug calls when I finally get to tidy the >>> module, so one can check what exactly went wrong with ODBC. >>> GetRecordCount() basically gets to the last record, grabs its row >>> number and returns it as the row count. It tries not to alter the >>> current rowset position. If for any reason it cannot do it (for >>> example due to having a non-scrollable rowset), it will return the >>> usual -1 for backwards-compatibility with the original >>> SQLRowCount(). >>> I tested it several times with two different MSSql servers at work >>> using different FreeTDS protocol versions and even over the internet, >>> and it seems to work. If you smell anything suspicious in it, just >>> say the word! >>> Regards, zxMarce. >> Hi, >> I have just merged your changes, changing some spaces in the code, and >> fixing the warning on 64 bits (SQLINTEGER is an int, so it requires "%d" >> in fprintf, not "%ld"). >> I think it would be better if you commit your changes directly in the >> subversion repository. >> Regards, > > Beno?t, > > Wow, better late than never. Just saw your response. Thank you. Still > remains the LIMIT handling and general code tidying. > > Thanks a lot also for the SVN direct commit offer, I'll give it a > thought or two. I'll also get some info on SVN and how it works. > Meanwhile, since I'm not a user of SVN, just in case I'll decline: Don't > want to trash the whole of Gambas on a bad commit! > > Regards, > zxMarce. > This is why we use SVN : you can rollback any change, and have a history of all of them. Just create an account on sourceforge and give me your user name, and I will grant you a write access. Then read the "How to deal with Subversion" page on the wiki. http://gambaswiki.org/wiki/howto/svn Regards, -- Beno?t Minisini From taboege at ...176... Mon Mar 14 13:52:31 2016 From: taboege at ...176... (Tobias Boege) Date: Mon, 14 Mar 2016 13:52:31 +0100 Subject: [Gambas-devel] [Gambas-devel-svn] SF.net SVN: gambas:[7634] gambas/trunk/comp/src/gb.markdown In-Reply-To: References: Message-ID: <20160314125231.GA12926@...693...> Hi Benoit, On Mon, 14 Mar 2016, tobiasboe at ...1... wrote: > Revision: 7634 > http://sourceforge.net/p/gambas/code/7634 > Author: tobiasboe > Date: 2016-03-14 12:36:03 +0000 (Mon, 14 Mar 2016) > Log Message: > ----------- > [GB.MARKDOWN] > * NEW: Markdown.Reinterpret is a new property to say if the next return of Command() should be reinterpreted as markdown or not. It is True by default for backwards compatibility. > > Modified Paths: > -------------- > gambas/trunk/comp/src/gb.markdown/.info > gambas/trunk/comp/src/gb.markdown/.src/Markdown.class > gambas/trunk/comp/src/gb.markdown/.src/Markup.module > I did this to implement a source code highlighter for Gambas code snippets in a Markdown class which uses gb.eval.highlight's TextHighlighter.ToHTML(), a la: @{code test.class} The TextHighlighter already outputs HTML which should not be reinterpreted as Markdown, obviously. Attached is a picture of the class rendering its own source code. Is the property name OK? Can you generate the documentation page for this property in the wiki or tell me how to do it? Also wouldn't you agree that syntax highlighting would be a nice addition to the wiki? Regards, Tobi -- "There's an old saying: Don't change anything... ever!" -- Mr. Monk From taboege at ...176... Mon Mar 14 13:58:19 2016 From: taboege at ...176... (Tobias Boege) Date: Mon, 14 Mar 2016 13:58:19 +0100 Subject: [Gambas-devel] [Gambas-devel-svn] SF.net SVN: gambas:[7634] gambas/trunk/comp/src/gb.markdown In-Reply-To: <20160314125231.GA12926@...693...> References: <20160314125231.GA12926@...693...> Message-ID: <20160314125819.GB12926@...693...> On Mon, 14 Mar 2016, Tobias Boege wrote: > Attached is a picture of the class rendering its own > source code. Not that the picture is important, but here it is. -- "There's an old saying: Don't change anything... ever!" -- Mr. Monk -------------- next part -------------- A non-text attachment was scrubbed... Name: highlight.png Type: image/png Size: 29083 bytes Desc: not available URL: From gambas at ...1... Mon Mar 14 14:04:09 2016 From: gambas at ...1... (=?UTF-8?Q?Beno=c3=aet_Minisini?=) Date: Mon, 14 Mar 2016 14:04:09 +0100 Subject: [Gambas-devel] [Gambas-devel-svn] SF.net SVN: gambas:[7634] gambas/trunk/comp/src/gb.markdown In-Reply-To: <20160314125231.GA12926@...693...> References: <20160314125231.GA12926@...693...> Message-ID: <56E6B6C9.8090707@...1...> Le 14/03/2016 13:52, Tobias Boege a ?crit : > Hi Benoit, > > On Mon, 14 Mar 2016, tobiasboe at ...1... wrote: >> Revision: 7634 >> http://sourceforge.net/p/gambas/code/7634 >> Author: tobiasboe >> Date: 2016-03-14 12:36:03 +0000 (Mon, 14 Mar 2016) >> Log Message: >> ----------- >> [GB.MARKDOWN] >> * NEW: Markdown.Reinterpret is a new property to say if the next return of Command() should be reinterpreted as markdown or not. It is True by default for backwards compatibility. >> >> Modified Paths: >> -------------- >> gambas/trunk/comp/src/gb.markdown/.info >> gambas/trunk/comp/src/gb.markdown/.src/Markdown.class >> gambas/trunk/comp/src/gb.markdown/.src/Markup.module >> > > I did this to implement a source code highlighter for Gambas code snippets > in a Markdown class which uses gb.eval.highlight's TextHighlighter.ToHTML(), > a la: > > @{code test.class} > > The TextHighlighter already outputs HTML which should not be reinterpreted > as Markdown, obviously. Attached is a picture of the class rendering its own > source code. > > Is the property name OK? Can you generate the documentation page for this > property in the wiki or tell me how to do it? Also wouldn't you agree that > syntax highlighting would be a nice addition to the wiki? > > Regards, > Tobi > You didn't have to add a property for that. You just had to a implement a special support of "[[ html" / "]]" for verbatim HTML in the Enter() and Leave() command. I will do it for you later. Regards, -- Beno?t Minisini From gambas at ...1... Mon Mar 14 14:04:34 2016 From: gambas at ...1... (=?UTF-8?Q?Beno=c3=aet_Minisini?=) Date: Mon, 14 Mar 2016 14:04:34 +0100 Subject: [Gambas-devel] [Gambas-devel-svn] SF.net SVN: gambas:[7634] gambas/trunk/comp/src/gb.markdown In-Reply-To: <20160314125819.GB12926@...693...> References: <20160314125231.GA12926@...693...> <20160314125819.GB12926@...693...> Message-ID: <56E6B6E2.4040505@...1...> Le 14/03/2016 13:58, Tobias Boege a ?crit : > On Mon, 14 Mar 2016, Tobias Boege wrote: >> Attached is a picture of the class rendering its own >> source code. > > Not that the picture is important, but here it is. > Anyway, that's great. :-) -- Beno?t Minisini From taboege at ...176... Mon Mar 14 14:08:46 2016 From: taboege at ...176... (Tobias Boege) Date: Mon, 14 Mar 2016 14:08:46 +0100 Subject: [Gambas-devel] [Gambas-devel-svn] SF.net SVN: gambas:[7634] gambas/trunk/comp/src/gb.markdown In-Reply-To: <56E6B6C9.8090707@...1...> References: <20160314125231.GA12926@...693...> <56E6B6C9.8090707@...1...> Message-ID: <20160314130846.GC12926@...693...> On Mon, 14 Mar 2016, Beno??t Minisini wrote: > Le 14/03/2016 13:52, Tobias Boege a ?crit : > > Hi Benoit, > > > > On Mon, 14 Mar 2016, tobiasboe at ...1... wrote: > >> Revision: 7634 > >> http://sourceforge.net/p/gambas/code/7634 > >> Author: tobiasboe > >> Date: 2016-03-14 12:36:03 +0000 (Mon, 14 Mar 2016) > >> Log Message: > >> ----------- > >> [GB.MARKDOWN] > >> * NEW: Markdown.Reinterpret is a new property to say if the next return of Command() should be reinterpreted as markdown or not. It is True by default for backwards compatibility. > >> > >> Modified Paths: > >> -------------- > >> gambas/trunk/comp/src/gb.markdown/.info > >> gambas/trunk/comp/src/gb.markdown/.src/Markdown.class > >> gambas/trunk/comp/src/gb.markdown/.src/Markup.module > >> > > > > I did this to implement a source code highlighter for Gambas code snippets > > in a Markdown class which uses gb.eval.highlight's TextHighlighter.ToHTML(), > > a la: > > > > @{code test.class} > > > > The TextHighlighter already outputs HTML which should not be reinterpreted > > as Markdown, obviously. Attached is a picture of the class rendering its own > > source code. > > > > Is the property name OK? Can you generate the documentation page for this > > property in the wiki or tell me how to do it? Also wouldn't you agree that > > syntax highlighting would be a nice addition to the wiki? > > > > Regards, > > Tobi > > > > You didn't have to add a property for that. > > You just had to a implement a special support of "[[ html" / "]]" for > verbatim HTML in the Enter() and Leave() command. I will do it for you > later. > Ah! I always wondered what these table syntaxes were useful for :-) -- "There's an old saying: Don't change anything... ever!" -- Mr. Monk From gambas at ...1... Mon Mar 14 15:16:41 2016 From: gambas at ...1... (=?UTF-8?Q?Beno=c3=aet_Minisini?=) Date: Mon, 14 Mar 2016 15:16:41 +0100 Subject: [Gambas-devel] [Gambas-devel-svn] SF.net SVN: gambas:[7634] gambas/trunk/comp/src/gb.markdown In-Reply-To: <20160314130846.GC12926@...693...> References: <20160314125231.GA12926@...693...> <56E6B6C9.8090707@...1...> <20160314130846.GC12926@...693...> Message-ID: <56E6C7C9.3020905@...1...> Le 14/03/2016 14:08, Tobias Boege a ?crit : > On Mon, 14 Mar 2016, Beno??t Minisini wrote: >> Le 14/03/2016 13:52, Tobias Boege a ?crit : >>> Hi Benoit, >>> >>> On Mon, 14 Mar 2016, tobiasboe at ...1... wrote: >>>> Revision: 7634 >>>> http://sourceforge.net/p/gambas/code/7634 >>>> Author: tobiasboe >>>> Date: 2016-03-14 12:36:03 +0000 (Mon, 14 Mar 2016) >>>> Log Message: >>>> ----------- >>>> [GB.MARKDOWN] >>>> * NEW: Markdown.Reinterpret is a new property to say if the next return of Command() should be reinterpreted as markdown or not. It is True by default for backwards compatibility. >>>> >>>> Modified Paths: >>>> -------------- >>>> gambas/trunk/comp/src/gb.markdown/.info >>>> gambas/trunk/comp/src/gb.markdown/.src/Markdown.class >>>> gambas/trunk/comp/src/gb.markdown/.src/Markup.module >>>> >>> >>> I did this to implement a source code highlighter for Gambas code snippets >>> in a Markdown class which uses gb.eval.highlight's TextHighlighter.ToHTML(), >>> a la: >>> >>> @{code test.class} >>> >>> The TextHighlighter already outputs HTML which should not be reinterpreted >>> as Markdown, obviously. Attached is a picture of the class rendering its own >>> source code. >>> >>> Is the property name OK? Can you generate the documentation page for this >>> property in the wiki or tell me how to do it? Also wouldn't you agree that >>> syntax highlighting would be a nice addition to the wiki? >>> >>> Regards, >>> Tobi >>> >> >> You didn't have to add a property for that. >> >> You just had to a implement a special support of "[[ html" / "]]" for >> verbatim HTML in the Enter() and Leave() command. I will do it for you >> later. >> > > Ah! I always wondered what these table syntaxes were useful for :-) > Yep. I will send you another kind of implementation for what you need. Regards, -- Beno?t Minisini From taboege at ...176... Tue Mar 15 18:45:24 2016 From: taboege at ...176... (Tobias Boege) Date: Tue, 15 Mar 2016 18:45:24 +0100 Subject: [Gambas-devel] [Gambas-devel-svn] SF.net SVN: gambas:[7637] gambas/trunk/gb.xml/src/textnode.cpp In-Reply-To: References: Message-ID: <20160315174524.GB7389@...693...> On Tue, 15 Mar 2016, tobiasboe at ...1... wrote: > Revision: 7637 > http://sourceforge.net/p/gambas/code/7637 > Author: tobiasboe > Date: 2016-03-15 17:16:58 +0000 (Tue, 15 Mar 2016) > Log Message: > ----------- > [GB.XML] > * BUG: Fix copy & paste error (?) which creates CDATA nodes as comment nodes. > > Modified Paths: > -------------- > gambas/trunk/gb.xml/src/textnode.cpp > Adrien, if you are here, could you check on this fix? I found this bug by a CDATA node which obviously contained data in my XML file but returned an empty TextContent and was later serialised to a comment. Alas, I'm not so familiar with the XML theory to justify the change. Regards, Tobi -- "There's an old saying: Don't change anything... ever!" -- Mr. Monk From adrien.prokopowicz at ...176... Wed Mar 16 02:00:16 2016 From: adrien.prokopowicz at ...176... (Adrien Prokopowicz) Date: Wed, 16 Mar 2016 02:00:16 +0100 Subject: [Gambas-devel] [Gambas-devel-svn] SF.net SVN: gambas:[7637] gambas/trunk/gb.xml/src/textnode.cpp In-Reply-To: <20160315174524.GB7389@...693...> References: <20160315174524.GB7389@...693...> Message-ID: Le Tue, 15 Mar 2016 18:45:24 +0100, Tobias Boege a ?crit: > On Tue, 15 Mar 2016, tobiasboe at ...1... wrote: >> Revision: 7637 >> http://sourceforge.net/p/gambas/code/7637 >> Author: tobiasboe >> Date: 2016-03-15 17:16:58 +0000 (Tue, 15 Mar 2016) >> Log Message: >> ----------- >> [GB.XML] >> * BUG: Fix copy & paste error (?) which creates CDATA nodes as comment >> nodes. >> >> Modified Paths: >> -------------- >> gambas/trunk/gb.xml/src/textnode.cpp >> > > Adrien, if you are here, could you check on this fix? I found this bug by > a CDATA node which obviously contained data in my XML file but returned > an > empty TextContent and was later serialised to a comment. Alas, > I'm not so familiar with the XML theory to justify the change. > > Regards, > Tobi > The fix looks good to me, it was indeed a copy & paste error. Right now I'm looking to get the gb.xml components covered by unit tests, these errors are starting to be really annoying ... Anyway, thanks for the fix. :-) Regards, -- Adrien Prokopowicz