garth's Journal http://use.perl.org/~garth/journal/ garth's use Perl Journal en-us use Perl; is Copyright 1998-2006, Chris Nandor. Stories, comments, journals, and other submissions posted on use Perl; are Copyright their respective owners. 2012-01-25T02:30:17+00:00 pudge pudge@perl.org Technology hourly 1 1970-01-01T00:00+00:00 garth's Journal http://use.perl.org/images/topics/useperl.gif http://use.perl.org/~garth/journal/ Dearth of camelbones apps http://use.perl.org/~garth/journal/10354?from=rss <p>A couple of people have mentioned on the <a href="http://archive.develooper.com/macosx@perl.org">macosx list</a> about the lack of applications/examples using camelbones. Other than the excellent examples by Sherm that come with the framework, <a href="http://rubberband.org/code/journalx">JournalX</a> (toot, toot!) seems to be the only other application using the framework with the source available. Considering the amount of people that wanted a macosx perl GUI tool I am amazed by this situation. Is it just that there aren't many perl programmers using OS X? Or is it just that perl programmers aren't fans of writing GUI apps?</p><p>On the JournalX front, I haven't done much work on it lately, not that there are any users of it other than me<nobr> <wbr></nobr>:-) I have started to fix a few bugs in the current version, and I am working on adding french localization. I think I will wait until the new camelbones version comes out before I release anything, to see what happens on the packaging front.</p><p>I have also been daydreaming about creating a CPANPLUS front-end with camelbones. I have built a simple interface with IB, but I have hit a few snags with the design. I need a way to use the apple security procedures to allow for installation into the system perl directories. After ready the <a href="http://developer.apple.com/techpubs/macosx/CoreTechnologies/securityservices/authorizationservices/authorization_concepts/index.html">Authorization Services API</a>, using AuthorizationExecuteWithPrivileges() seems to be the way to go, but I am not really sure how I should deal with displaying progress, and how to deal with prompts from the installer/testing. I am sure I will eventually figure out the solution, and then hit another stumbling block<nobr> <wbr></nobr>:-)</p> garth 2003-02-03T08:07:28+00:00 journal French and a test http://use.perl.org/~garth/journal/8514?from=rss <p>I had my first french lesson tonight, which was fun. I have never learnt another language, so I am not really sure about the whole process, however I can see that learning the gender of all the nouns may take me a while. I plan on calling up my mother regularly, who used to be a french teacher, to subject her to my terrible attempts at this beautiful language.</p><p>Going to the class ment I missed the Sydney PM meeting with Dave Cross, which was the first since I joined the list. Hopefully they will have another in the near future which is better suited to my ample free time.</p><p>Oh and this entry is also to test the fix by Pudge (not that I don't trust him) has made for the SOAP comments bug. If it works, comment should be disabled for this entry. If not, it probably just means he has not implemented it on use perl yet.</p> garth 2002-10-22T11:50:19+00:00 journal Forgot http://use.perl.org/~garth/journal/6853?from=rss <p>I forgot to mention, there seems to be a bug in Slash where you can't turn off comments for a new Journal entry if you have them on as default. It only seems to effect entries done through SOAP though.</p><p>I filed a <a href="https://sourceforge.net/tracker/index.php?func=detail&amp;aid=589943&amp;group_id=4421&amp;atid=104421">bug</a> at the sourceforge page for Slash, and produced a patch which I think fixes the problem, but I have no way to test. Anyway, it is just something to remember if you are using JournalX.</p> garth 2002-08-02T03:57:55+00:00 journal JournalX v0.2 http://use.perl.org/~garth/journal/6852?from=rss <p>I've uploaded a new version of JournalX, with a few new features, and a whole heap of cleaning up of various bits and pieces. The new version, along with the source, and a few screenshots can be found <a href="http://rubberband.org/code/journalx">here</a>.</p><p>The main changes are:</p><p>- Fixed main window, to allow resizing<br>- Added ability to delete existing entries<br>- Added ability to edit and overwrite existing entries<br>- Updated offline entry maintenance, now able to selectively upload or delete entries<br>- Comments link can now be clicked<br>- Changed menu items</p><p>The instructions for use are the same as the last version, which are <a href="http://use.perl.org/~garth/journal/5070">here</a>.</p> garth 2002-08-02T03:26:00+00:00 journal Finally some good news http://use.perl.org/~garth/journal/6627?from=rss <p>After six weeks in the repair shop, my ibook finally came home today. Supposedly all that was wrong with it was a cable to the backlight was dead, yet it still took them six weeks to fix.</p><p>Hopefully this weekend I can finish off the next version of the JournalX, which only has a few more things I want to add.</p><p>Oh, and an update on my ad. So far it has had 4898 impressions, with a grant total of 51 click throughs to the Camelbones website. I think next time I might need to work on my spruiking ability, or at least come up with a dirty limerick to catch peoples attention.</p><p> &nbsp;</p> garth 2002-07-25T11:52:27+00:00 journal TextAd http://use.perl.org/~garth/journal/5852?from=rss <p>As part of the fundraiser on <a href="http://www.kuro5hin.org/">Kuro5hin</a> I bought a textad for Camelbones. As ever, my creative side let me down and it is a pretty boring ad, but it supports two things I enjoy, so that is good. You can see the ad <a href="http://www.kuro5hin.org/story/2002/6/20/19948/2626">here</a></p><p>In the 24 hours it has been running so far, it has been shown 245 times, and had 3 clicks. With a click through percentage of 1.22%, it probably beats most normal banner ads, but there are about 24750 more impressions to be used, so it will be interesting to see where it ends.</p> garth 2002-06-22T00:11:24+00:00 journal Soccer Handbags http://use.perl.org/~garth/journal/5624?from=rss <p>Amusing <a href="http://atschool.eduweb.co.uk/swright/worldcup/handbags.jpg">Link</a> Of The Day<nobr> <wbr></nobr>:-)</p><p>Oh how wonderful it has been to have the World Cup near our timezone. No more staying up till 3am to watch a match, only to fall asleep at the kickoff.</p><p>I wonder how much extra weight the Australian population (and the rest of the world) will gain this month by sitting on the couch for hours on end.</p> garth 2002-06-13T02:21:06+00:00 journal Camelbones Foundation Functions http://use.perl.org/~garth/journal/5355?from=rss <p>Unlike the auto-conversion from scalar to NSString that occurs for object messages, the declared foundation and appkit function in camelbones expect scalar references for the NSString arguments. There probably is a reason for this, but with my limited XS knowledge, I don't think I am ever going to find out why<nobr> <wbr></nobr>:-)</p><p>Oh well, it only took me a couple of hours to figure this out, and now I have written it down, I hopefully won't forget.</p> garth 2002-06-01T11:02:53+00:00 journal todo http://use.perl.org/~garth/journal/5073?from=rss Things for next version:<ul> <li>Clean up interface, make labels consistent, do something with progress indicator</li><li>Add menu/button for refreshing reading list</li><li>Add ability to delete and edit existing entries</li><li>Fix comment link so it actually can be clicked<nobr> <wbr></nobr>:-)</li><li>Make offline entries easier to manage, e.g. edit, delete, selectivly upload, datestamp</li><li>Fix warnings from sheets ( and others )</li><li>Try and figure out how to make the cursor change when over a link, i.e. subclassing NSTextView like <a href="http://www.sra.co.jp/people/hoshi/macosx/prog-tips.html">CocoaBrowser</a> </li></ul> garth 2002-05-19T11:12:13+00:00 journal JournalX v0.1 http://use.perl.org/~garth/journal/5070?from=rss <p>The application: <a href="http://rubberband.org/code/JournalX_v0.1.1.dmg.gz">JournalX</a></p><p>The source: <a href="http://rubberband.org/code/JournalX_src.tar.gz">JournalX Source</a></p><p>You need to know your uid for the site to get your journal, which can be found on the front page when you are logged into the site. You also need to fill in your user details in your preferences before anything can happen.</p><p>The following modules are required:<br><code>HTTP::Cookies<br>SOAP::Lite<br>Digest::MD5<br>Date::Simple<br></code></p><p>If anyone actually uses it, or has any suggestions for improvments, I would love to hear from you<nobr> <wbr></nobr>:-)</p><p><i>Update:</i> Looks like the executable/bundle doesn't bring the camelbones framework along with it. So, to run the application, you need to install the camelbones framework, which can be downloaded from <a href="http://sf.net/projects/camelbones">here</a></p><p><i>Update again:</i>Second time lucky, hopefully. The link above now goes to a newer version of the application, which has the framework as part of the application bundle. It should work without needing to download the camelbones framework yourself.</p> garth 2002-05-19T03:05:52+00:00 journal screenshot http://use.perl.org/~garth/journal/4864?from=rss <p>Here is a <a href="http://rubberband.org/screen.jpg">screenshot</a> of the application.</p><p>Still need to figure out a better name, create an icon, and fix up a few things before I release it. Not sure if anyone would actually use it, but it is a decent example for CamelBones stuff.</p> garth 2002-05-12T08:26:54+00:00 journal ibook and interface builder http://use.perl.org/~garth/journal/4863?from=rss <p>Since the motherboard on my PC died a few weeks ago, I have been using my ibook exclusively. I've had the thing nearly a year, but this is the first time I have really used it a lot. I've ripped my important cds in iTunes, played around with iPhoto, and marvelled at the wonders of Interface Builder and Project Builder.</p><p>To continue on my quest to write more perl, I have been playing around <a href="http://sf.net/projects/camelbones">CamelBones</a> for a while. Using the amazing IB, I have built a OS X program to write use.perl; journal entries through the SOAP interface. Nothing ground breaking, but I was quite amazed at how simple the GUI stuff was. I am quite impressed at how easy it seems to be to write these applications with Cocoa (and now perl), by just dragging the elements where you want them, and connecting the interface to the classes. Plus you still get all the extra Cocoa stuff, like spell checking, for free when using CamelBones.</p> garth 2002-05-12T08:07:46+00:00 journal SOAP Interface (Not) Broken, plus Camebones Question http://use.perl.org/~garth/journal/4418?from=rss <p>Is the SOAP interface to use.perl broken at the moment? I have been trying to use it to create a journal entry, but everytime the body of the entry comes up as just the word 'date'.</p><p>While this could be the universe trying to tell me I need to get out more, I am pretty certain that there is something wrong in the back end. Even using pudge's <a href="http://use.perl.org/~pudge/journal/3294">example script</a> gives the same result as my program.</p><p>Oh, and while I am asking questions, does any know if it is possible to create an NSString object in camelbones? All my current attempts result in a scalar being returned, which is not what I need.</p> garth 2002-04-24T10:16:56+00:00 journal Cocoa For Cheapskates http://use.perl.org/~garth/journal/3710?from=rss <p>I wrote my first Cocoa program last night. I needed a timer for when I am cooking, so instead of doing the simple thing and buying an egg timer, I decided to try and make a countdown timer program on my iBook.</p><p>It was suprisingly easy, the only difficult bit was trying to figure out how to set fonts in the text fields. If you actually knew what you were doing, it probably could have been done in twenty minutes. I think I will try to add some preferences and extra stuff tonight, then release it to the world, because I am sure there must be millions of people out there who need a Cocoa countdown timer<nobr> <wbr></nobr>:-)</p><p>Not much progress in the land of perl for the last week or so. I added support for multiple symbols to the module, so it produces graphs showing the percentage gain/loss over a period of time. Thats about the last of the functionality I want to add, so I think it might be time to apply for a CPAN id, finish the documentation, and see about adding a few more tests.</p> garth 2002-03-21T23:21:30+00:00 journal I can't sing, but I got soul http://use.perl.org/~garth/journal/3213?from=rss <p>Finally got to spent some time to work on my module tonight, while sitting watching the Grammys (we are a bit slow in Australia with these things). Started adding parameters to make everything more configurable, and adding tests to make sure I am actually doing what I mean to. Looking good so far, but I think I need to investigate Test::GD that someone mentioned a while ago. And to top it off, U2 won a couple of awards, so I was quite happy.</p><p>I have got to a point with the graphs my module is producing that I am hitting problems with GD::Graph. I want my graphs to have ticks on the x-axis at varying intervals, like for the varying amount of days between the first day of a month. However, GD::Graph only give evenly spaced ticks. I think I might release a first version of the module before tackling the problem, and then maybe look at adding the functionality to GD::Graph if possible, otherwise add it to a future version of my module.</p> garth 2002-03-01T11:42:19+00:00 journal Fight Club http://use.perl.org/~garth/journal/2683?from=rss <p>Finshed reading Fight Club tonight. Quite an odd book really, spent half my time reading it wondering whether it was appropriate material to be laughing at. I think I liked it, so I might have to pick up some more of Chuck's stuff. Probably should have a look at the movie too. Need some lighter reading next though, so it is onto some more Lemony Snicket books.</p><p>Not much module progress over the last week or so, as I have been busy preparing/packing to move.</p> garth 2002-02-06T11:25:56+00:00 journal Golf http://use.perl.org/~garth/journal/2597?from=rss <p>As I was watching bits of the golf on TV this afternoon, I read about the golf challenge in the Perl Review mag, and thought I would give it a try. My <a href="http://use.perl.org/comments.pl?sid=2962&amp;cid=3989">first attempt</a> had the slight bug of it only working on one digit numbers, but undetered I solidered on.</p><p>I think my latest attempt actually works correctly, but has 74 characters:</p><p><tt>for(split<nobr> <wbr></nobr>//,reverse shift){$c+=(ord()-(/\d/?48:55))*(36**$p++);}print $c;<br></tt><br>After looking at some of the <a href="http://use.perl.org/comments.pl?sid=2962&amp;cid=3959">other</a> <a href="http://www.perlmonks.org/index.pl?node_id=142759">solutions</a>, it would seem I need to get out the camel and read up on <tt>map</tt> and <tt>y///</tt>, as I am not really sure how these work. Who would of thought converting different base numbers could actually be fun and educational<nobr> <wbr></nobr>:-)</p> garth 2002-02-02T08:56:31+00:00 journal The Module http://use.perl.org/~garth/journal/2491?from=rss <p>The long weekend gave me a chance to get started on my module. Currently it is called Finance::ChartHist, and basically produces graphs of a share price between two dates. The same as can be found on any financial website, such as Yahoo. I don't think there will be many other people that will find it useful, but it should be fun to build, and gives me a chance to get back into using perl.</p><p>Most of the grunt work is already provided by existing modules, namely Finance::QuoteHist which gets historical price information from various websites, and GD::Graph which produces pretty graphs. I got the basic outline of what I want done on the weekend, producing simple graphs, automatically formating the labels for the axis, etc. Most things are hardcoded at the moment, with the only options being the dates and ticker symbol currently, so I think my next step should be offering more options to format the graph.</p> garth 2002-01-29T09:45:18+00:00 journal The beginning http://use.perl.org/~garth/journal/2460?from=rss <p>One of my goals for this year is to write more Perl. To make this a reality, I decided that I need to write at least one CPAN module by the end of the year. Not hard you might say, but for someone with the attention span of a gold fish like me, it might be a challenge.</p><p>Anyway, so I can try to keep track of what I am doing, and so other people can laugh at my slow progress, I though I would start a journal here<nobr> <wbr></nobr>:-)</p> garth 2002-01-28T03:49:14+00:00 journal