Results 1 to 8 of 8

Thread: Determining CCF name or size from LUA

  1. #1
    Join Date
    Mar 2005
    Location
    Los Angeles, CA
    Posts
    1,003

    Default Determining CCF name or size from LUA

    Is there a way to determine the current CCF's name or size from LUA? I'd like to do handle both the big and little versions of my CCF with the same LUA script, but there are a few things that need to vary between them (such as size of icon graphics, number of GAC items that will appear, etc).

    Thanks,
    Tim

  2. #2
    Join Date
    Nov 2003
    Location
    Hove, E Sussex, UK
    Posts
    4,005

    Default

    I seperated out my lua, stuff so the common stuff is in NR/LUA folder.

    Functions which require to know the size of the ccf, are called from the ccf's lua file with "big", "small" or other such terms like "ppc" or "win32"
    Thx, Dan

    Onwards and Upwards!
    http://www.danward.co.uk

  3. #3
    Join Date
    May 2004
    Location
    Cardigan, UK
    Posts
    9,278

    Default

    There's NR.FILE.Name

    I don't think there's a way to get the size of a CCF, but you can get the position of an element using NetRemote.GetElementPosition() which you could use as a workaround.
    --Rob

  4. #4
    Join Date
    May 2002
    Location
    CT
    Posts
    6,559

    Default

    What about using NRCFG.DeviceWidth and NRCFG.DeviceHeight? I'm assuming both versions are full screen, so this should match.

  5. #5

    Default

    Are all these variables documented somewhere?

    It would be nice if, each time a new release is posted, there is also a link to the updated guide (change-barred if possible). If this means we have to wait longer for new releases while you update the documentation then so be it is what I say. Everybody wins in the end. IMO updating and reissuing the Guide should be considered an essential aspect of the release - not a 'nice to have'.
    JLee
    OpusNR & JLee CCF/GML available in the downloads section.

  6. #6
    Join Date
    May 2004
    Location
    Cardigan, UK
    Posts
    9,278

    Default

    Well, they're 'documented' in the variable inspector of NR Designer
    --Rob

  7. #7

    Default

    So they are. I never even looked at that function before ops:
    JLee
    OpusNR & JLee CCF/GML available in the downloads section.

  8. #8
    Join Date
    Mar 2005
    Location
    Los Angeles, CA
    Posts
    1,003

    Default

    Thanks for all the suggestions! I wound up building the size into my file name, and just parsing it our of NR.FILE.Name.

    Since I run my small CCF's on Win32 (not fullscreen) as well as on PPC (fullscreen), the DeviceWidth can be deceiving, so by encoding it in the filename, I know exactly what width panels I'm running with. That did the trick, so thanks again!

    Cheers,
    Tim

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •