June25
I had a UIButton inside a UITableViewCell and these were being rendered with a black background once I had upgraded the project to iPhone OS 3.0. These table cells were being loaded from their own NIB file.
To stop the black background I needed to set the background of the TableViewCell to white (like you do on most cells after the upgrade), but for the button I also needed to set the UIButton to have the “Clear Context Before Drawing” setting checked.
The background should still be transparent to allow the corners of grouped tables to be shown.
January14
I was receiving the following error while trying to run my unit tests from XCode:
Test Host –path to app– exited abnormally with code 138
For whatever reason, removing the tests from the Unit Tests target and re adding them to the target made the error go away. No other changes necessary.
December30
Here is the article that explains how to add unit testing to XCode 3 project.
http://developer.apple.com/mac/articles/tools/unittestingwithxcode3.html
If you search for unit testing with XCode you will find a lot of older articles pointing to XCode 2.x and how to install etc, etc. Now XCode 3 includes unit testing out of the box, so it is a lot simpler.
December28
Came across an interesting problem. Trying to get distributed objects to pass a common class between processes.
To avoid versioning issues I had the class in a shared location so that both client and server could use it.
On the server I was seeing a decodeRetainedObject: class ‘bleh’ not loaded error in the console log. Took a while to figure out, but XCode doesn’t automatically assign a class that are dragged and dropped into a project to the main target. The files simply needed to be assigned to the requisite target and everything works fine.
September23
Recently I did a presentation at the Melbourne Cocoahead, and recorded the screencast.
Here is the first part, a 24 minute demonstration of adding sparkle to a cocoa application.
The next 2 parts will hopefully be added in the next couple of weeks.
May17
Just another update NSTableView and creating it dynamically. If the NSTableView has its frame set then column resizing and scrolling seems to be screwed up.
By setting the frame of the scrollview and simply just calling init the NSTableView then the table seems to work correctly.
[tags]Cocoa[/tags]
May16
If you need to add a NSTableView to a window or view in your code then it is not immediately obvious how to do this.
For example adding a button, all you need to do is initWithFrame for the button, then add the button to the main view.
However a NSTableView isn’t that simple. When you drag one out using interface builder you are getting a NSTableView wrapped up in a ScrollView. If you try to add the same way you would an NSButton you can’t see anything. What is needed is a ScrollView to wrap up the tableview.
I found this code which outlines how to setup a NSTableView. It is on the excellent cocoadev web site.
[tags]Cocoa, NSTableView, CocoaDev[/tags]
May10
I have a number of projects that use Microsoft’s Enterprise Library, but usually they use Integrated Security to connect to the SQL Server. Yesterday I had a project which had to connect to a SQL Server via username and password and found it wasn’t the easiest to work out how the dataconfiguration file should be set up. This is what I came up with that worked:
<connectionstring name="Sql Connection String">
<parameters>
<parameter name="Data Source" value="Server" isSensitive="false" />
<parameter name="Initial Catalog" value="Database" isSensitive="false" />
<parameter name="Integrated Security" value="false" isSensitive="false" />
<parameter name="Connection Timeout" value="10" isSensitive="false" />
<parameter name="user" value="sa" isSensitive="false" />
<parameter name="password" value="sa" isSensitive="false" />
</parameters>
</connectionstring>
May3
At present I am working on Version 2.0 of Duplicate Image Detector. At present it is nearly as quick as V1.0 for detecting duplicates, and it is now a matter of getting the user interface hooked up.
Version 2.0 will have the following goals:
- Simplified User Interface
- Easier access to advanced features
- Same speed as version 1.0
At present the user interface is coming along nicely and I beleive that it will be easier to use. In initial testing version 2.0 is nearly as quick as version 1.0 but still needs a bit of tweaking.
Once version 2.0 is out the door the next focus will be on improving the performance of the application.