Sometimes I wonder

Have you ever had an experience where you told somebody how something worked and asked them to not proceed until it had been tested completely, and then the person went ahead anyway and then when it was tested it turned out that you were right all along? Yep that’s how things go sometimes.

Anyhoo besides having one of those moments today I improved the API Reference even more. This time I modified the code so that if the columns have been resized, they don’t auto resize back to a 20/80 split when the user clicks a new class in the folder tree. Now I’m confident (yet again LOL) that the API Reference is done.

I need to do a little coding in Gideros tomorrow to separate the XML conversion code from the rest of the document generation code. This will be required for when the documentation is stored as JSON files, instead of XML files.

We visited with friends here in Kapiti today and it was good to catch up.Tomorrow we will go and get a few things from our house and then off to Waikanae to stay the night with more friends 🙂

Advertisements

One Step Forwards

Sometimes it feels like I go backwards more than I go forwards. @keszegh in the Gideros forums mentioned the API Reference does not include events! It has Methods and Constants but not Events! As it transpires, the XML file I used to create the initial documents did not include any Events and that is why the API Reference does not contain them… DOH.

Well it is good that he mentioned it and now I am well on the way to resolving that. He also mentioned (as well as others) that the new API Reference does not allow linking to specific classes and methods. It actually does but the link will open the class page in question and the folder tree in the left column will not be present.

Today I worked on that issue and I have it sorted. inks like this will take you to a specific method inside a class, and have the folder column available. It’s some pretty good magic IMHO 😉

I also reworked the column resizing code and there is now just one function that manages that and that function is called in different places in the actual script. I’m very happy with it now.

We arrived in Kapiti this evening and tomorrow we will catch up with friends and go to the house that Claire sold and replace a lightbulb, because you know.. tenants are sometimes not very good at such menial tasks 😀

Reality

Sometimes reality knocks on the door and whatever enjoyment you were having.. stops in short order. This was the case for me today and it looks dear readers that I’m going to have to get myself a job like 99% of the other poor bastards out there in the world. I suppose it was too good to think I could laze about all day programming games and stuff without actually making any money from it. I suppose I can say that I have been there and done that (not the money part however LOL).

As a slight reprieve I’m going to work on my book for a couple of months more and if that has not eventuated, or has eventuated and generated no income, it’s back to the 9-5 grind for me I’m afraid. I really find it all very not motivational 😦

Apart from that s**t cake I discovered that in the API Reference if you make the window quite small then the nav bar at the top of the page changes size. This had the unfortunate side effect of making the column layout do odd things *grr*. I’ve fixed it now and it works as intended. Always test thoroughly 🙂

There has been a bit of feedback in the forums about my API Reference system and people seem to want it to function in ways that it was never intended to. I suppose I’m just too simple minded because I find it a real pleasure to use. Oh well I guess you can’t make all of the people happy all of the time right? 😉

In other news Claire sold her house in Kapiti! It’s not a done deal until next Tuesday but nonetheless it’s pretty good news (for her anyway). So we are going down to Kapiti to visit friends (regardless if the house sold or not) so it should be a good weekend.

There is news about our kitchen issues and our dodgy electricians also but I’ll get to those next week 😉

Late Progress

Well it;s very late this evening and I’m just making a quick brain fart post (they all are really though heheh) 🙂

I’ve made good progress with the API Reference. I found a fantastic script called prism.js which takes <pre><code> blocks inside HTML files and turns them all pretty and colorful. Its just so good! It supports color themes and also heaps f language syntax. Sometimes it all depends on just what you search for in google 🙂

So that’s all good and I have also started revamping things so that even the API Reference has a navigation bar. Maybe we can get the forum to appear as part of the Gideros site too? Hmm 😉

Goodbye Hair!

I spent the day tearing my hair out. It doesn’t matter too much, I don’t need hair anyway. As with most things in this world, the simple solution is often the best. Unfortunately sometimes the simple solution doesn’t pop into your head until you have spent days exhausting more elaborate solutions. The latter has been the case so far with the Gideros website remake, especially with the API Reference that I keep swearing is working, and then it turns out there is some strange case where my tricky code fails and it all falls over on it’s virtual face.

So resizing columns has been driving me crazy. As the user drags the resizing handle about I get the windows width, do some funny calculations, and then set the right columns width, the left columns width, and the folder trees width. The sticky part is with the folder tree because they can have content that goes outside the left column. So that required recalculating the left column with variables for scroll bars and such. This worked mostly but in the end did not work consistently 😦

So about an hour ago I had a crazy idea. When the user is dragging the handle there is no need to even see the scroll bar in the left column so why not just turn it off with CSS (overflow-y:hidden;) and then when the mouse is released, turn it back on (overflow-y:scroll;). And you know what? It just works and magically does all the hard stuff for me!. There are no strange scrolling bugs at all just with these two lines of code. OMFSW!!!!

That has made the code for the API Reference smaller and cleaner which is nice. I also mashed up some code that resizes the columns and stuff when the user resizes the browser window. Currently this seems to be working as intended.. fingers crossed 😉

I also had fun with some of the API documents themselves. It turns out that if you use < and > characters in HTML the browser starts to process the next text as HTML instructions, doh! It took a long time to realize this and the solution was to replace all occurrences of < with &lt and > with &gt. This works nicely and the documents are looking mighty fine.

I tweaked the look and feel of the API Reference page so it looks nicer and now I’m pretty much thinking it’s complete. A good days work I think, and it seems to work in FireFox, Chrome, and IE 11 🙂

So Close…

I’ve been chatting to @Atavismus in the Gideros community Slack channel regarding the website upgrade. He has been quite motivational and providing valuable feedback which I really appreciate. So today I have been upgrading the API Reference because that;s what we discussed this morning, before Claire and I left for Coffee Group.

The API Reference is nearly working perfectly (in FireFox at least) and I’m confident that I can get it perfected tomorrow. I’ve redone the style sheet attached to it so the layout and colors are much nicer. I’ve also added links directly after the class description so you can more easily navigate to the different methods. That;s working really well and I’m pleased with it.

Another uphill battle in the Gideros Forums today. It seems that nobody gives a s**t about the Gideros Website and they just want all manner of stupid crap (IMHO) added to it. I guess they just don;t see the website’s purpose as I do. Oh well sometimes you have to go with the flow?

Syntactic Overload

Wow! Yesterday I thought that splitting a string up into a bunch of words and then gluing them all back together in a nice fancy HTML string would be pretty easy. This unfortunately is one of those times (that’s most of the time) when I was absolutely incorrect.. it’s really damn hard! I now have a better handle on how it might be accomplished but for now I’m going to shelve this because…

  • Getting it working will soak up a few entire days.
  • The API Reference already looks pretty good.
  • There’s way too much other website stuff to sort.

I’m a little disheartened about the response thus far on the Gideros forums about the new website. It seems the few people who have replied want all manner of whacky stuff included.. things I’m really reluctant to include.

In the Gideros Slack channels the other maintainers have been pretty stand offish, except for @totebo because he’s always there to give an opinion and assist!

With these points in mind I will continue on but really I am beginning to lose motivation. I’d much rather get back to NanoTron or Buzzy Beez, or any of my book. We will see how this pans out but it currently looks destined to fail 😦

Anyhoo it’s Sunday so you know what happens now… we ponder the great mystery that is religion…

religion_11_2_2018