Author Topic: Problem with menu separation line  (Read 3012 times)

0 Members and 1 Guest are viewing this topic.

Offline Goran

  • LV2 Member (Next: 40)
  • **
  • Posts: 32
  • Rating: +0/-0
    • View Profile
Problem with menu separation line
« on: September 30, 2012, 11:56:42 am »
Hello,

I am delighted with ability to specify my own menu for a script page using toolpalete:register() call.
I followed the example given in the Lua Scripting API Reference Guide.

Everything worked as described, except for separation lines (section dividers), specified by hyphen ("-"):
Instead of some kind of separation line, I get in the menu a disabled menu item (gray text) saying: "<number>: English (U.S.)".

Did anyone else experienced such a behavior?

Best regards,
Goran


Offline Jim Bauwens

  • Lua! Nspire! Linux!
  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1881
  • Rating: +206/-7
  • Linux!
    • View Profile
    • nothing...
Re: Problem with menu separation line
« Reply #1 on: September 30, 2012, 12:41:23 pm »
I've checked, and this is indeed a bug.
I assume that the grey line has a resource id, and that the code handling the menu system in Lua used a static number for it.
This resource ID most likely changed because of some updates to resource files, but the lua coders didn't change it.
Well, that's my theory.

I'll report it to TI.

Offline ElementCoder

  • LV7 Elite (Next: 700)
  • *******
  • Posts: 611
  • Rating: +42/-2
    • View Profile
Re: Problem with menu separation line
« Reply #2 on: October 01, 2012, 02:36:33 am »
So we do have contact with TI here? Wow that's quite nice.

Some people need a high five in the face... with a chair.
~EC

Offline Jim Bauwens

  • Lua! Nspire! Linux!
  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1881
  • Rating: +206/-7
  • Linux!
    • View Profile
    • nothing...
Re: Problem with menu separation line
« Reply #3 on: October 01, 2012, 02:49:27 am »
Several members have ;)

Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: Problem with menu separation line
« Reply #4 on: October 01, 2012, 05:28:48 am »
Don't worry I have reported it already :)

(About 1,5 months ago.)

The technical explanation behind this, is (thanks to levak for pointing this out) : the string loaded is probably non-valid and returns 0, which corresponds to the current language.

It is planned as fixed for the next major release (just got that confirmed a few days ago actually)


also :
Quote
So we do have contact with TI here? Wow that's quite nice.
Yes, from programmers (to which we report these kinds of bugs) to executives (useful for sharing "higher" feedback, ideas etc.)
« Last Edit: October 01, 2012, 06:23:32 am by adriweb »
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation