With the increase in chatter about exceptions with the upcoming release of API 2.0 I took a deeper look into the docs.
I might be missing something obvious but how is there no prominent list in the documentation for the exceptions related to each doc entry?
For example, and there are other occurances: http://docs.xojo.com/Font The Font method is index based, if you were a newcomer to Xojo stumbled upon that page, how would you know that an http://docs.xojo.com/OutOfBoundsException can even be raised by using that method? Are there any other exceptions that I should be concerned about?
In the doc page for http://docs.xojo.com/OutOfMemoryException I see a comment like "This exception is mostly useful with MemoryBlock and Picture", but it doesn't mention what else its useful for.
Another reason I looked into this was a conversation on Discord. There was a problem with a piece of code in windows that threw an odd exception (this is the simplified test sample not the live code so don't waste time pointing out the issue :)):
Dim p As New Picture(50, 50) p.Save(SpecialFolder.Desktop.Child("te""st.jpg"), picture.SaveAsJPEG)
I looked at http://docs.xojo.com/Picture.Save and there's no mention of that Method raising an exception or what exceptions it could raise.
I then looked at http://docs.xojo.com/FolderItem and there's one mention of an exception but its unrelated so again no mention of the exceptions that could be raised. https://docs.xojo.com/FolderItem.Child nothing related to the issue.
So I guess my concern is, how are users meant to find out what exceptions can be raised by the code they are using without having to revert back to http://docs.xojo.com/RuntimeException every time they write a line of code and checking it with a fine toothed comb or actively breaking their code to see what exceptions are raised?
Maybe we could have a nice prominent table somewhere on each page that raises an exception that lists the exceptions that can be raised so people know its even a thing that can happen?
Thoughts or have I missed something?