PxPlus User Forum

Twitter Twitter Twitter

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - steezware

Pages: [1] 2
1
Programming / Re: Multi-Line SELECTOFFSET, SELECTLENGTH, SELECTTEXT$
« on: December 11, 2023, 12:15:58 PM »
Thank you, Mike!

2
Programming / Re: Multi-Line SELECTOFFSET, SELECTLENGTH, SELECTTEXT$
« on: December 06, 2023, 02:22:21 PM »
Okay, putting this question/issue to rest. Arno was correct when he mentioned that making the multiline 2 rows high allowed for fetching 'SelectOffset, 'SelectLength and 'SelectText$.

So, I faked out my panel by making the multiline borderless and 2 lines high. I also messed around with making the font double-sized, which had an affect on fetching the offset and length.

Question to PxPlus is - why is it so difficult to fetch the offset and length of selected text in a multiline without work-arounds like making the control 2 rows high?

3
Programming / Re: Multi-Line SELECTOFFSET, SELECTLENGTH, SELECTTEXT$
« on: December 06, 2023, 12:45:40 PM »
Turns out that fetching 'SelectOffset and 'SelectLenght does work just fine, but the problem I am having turns out to be that the multiline control as it loses focus clears out the selection. So I need to figure out how to grab the offset/length when Nomads moves off the multiline before it loses focus?

I have tried 'Change and 'OnFocus and even thought maybe 'Validator or 'Formatter Nomads class functions would fire allow me to jump in and get the select offset/length, but no luck.

Or is there some multiline option/attribute that needs to be set to preserve the text selection when the multiline loses focus?

4
Programming / Multi-Line SELECTOFFSET, SELECTLENGTH, SELECTTEXT$
« on: December 04, 2023, 06:21:57 PM »
In a multi-line control I want to grab the portion of the text that the user has selected.

For example...
  • a multiline contains "Hello World Canada"
  • the user double-taps on "World" and it shows as selected, highlighted
  • they then click another control on the panel - or simply tab off the multiline
  • in the logic that follows I attempt to grab the 'SelectOffset and 'SelectLength attributes ... but on leaving the multiline the users "World" selection is lost - no longer selected
  • so what I really get in SelectOffset is 12, the zero-based offset for the "d" in "World"
  • I need to get values 6 and 5
This is in Nomads, under *Nomads object control, and I do not have any OnFocus or OnSelect logic tied to the multiline control either in the Nomads panel definition or in my UI class (although I have tried using them and signal-all-changes and signal-on-exit and everything else I could think of).

I can, of course, do a ML'SelectOffset=6 and ML'SelectLength=5 and manually highlight "World", so that works...

...but how to I grab "World" when the user selects it and leaves the multiline control?

Help? Thx!

5
Nomads / Re: Nomads Library Key - Byte (13,1)
« on: September 11, 2023, 10:13:39 AM »
That is exactly what I wrote in my post - 'values that approximate the location of a control' and that I know what U, M and X are ... my question was and is what specifically are the F, R, S, V and Y (13,1) 'types of information'?

6
Nomads / Nomads Library Key - Byte (13,1)
« on: September 07, 2023, 04:25:57 PM »
It's documented that bytes (13,4) of a Nomads record contain 0000 for a header record and then numeric values that approximate the location of a control on the window, and I also know of a few other characters that are used in the 13th byte of the key...

U : User-Defined CTLS
M : Menus
X : Grid settings

...but can somebody let me know (I'm just curious, don't really need to know) what Nomads records the following characters in (13,1) of the key represent...

FRSVY

Thx!

7
Programming / Menu Bar Height and Font
« on: August 29, 2023, 05:02:25 PM »
I have menu bars defined for some Nomads panels and was wondering if it is possible to modify the size (height) of the menu bar or the font/size that it uses. Maybe increasing the font size would automatically change the menu bar height - that would be nice.

After digging around I couldn't find an INI file override or an 'Option' on-the-fly action that changes the menu bar height/font.

Any suggestions? Thx!

8
Programming / Re: Accessing a Control on Another Dialog
« on: August 09, 2023, 07:14:02 PM »
Figured it out:

PRINT 'SWAP'
LB'Visible = 0 (I passed the LB control value into the new 'process)
PRINT 'SWAP'

Thx for the 'goto' idea but tried 'swap' first and it worked.

9
Programming / Accessing a Control on Another Dialog
« on: August 09, 2023, 06:19:35 PM »
So, I'm in a dialog and I want to access/update a control, say a listbox, on the window that spawned the current dialog with focus.

Seems like I used to know how to do this, but maybe it can't even be done?

Thx!

10
Programming / Programmatic Auto-Complete
« on: July 27, 2023, 01:26:52 PM »
I have a multi-line control with 'Autocomplete defined that works great. What I would like to do is have Nomads auto-complete open when I programmatically assign values to the control, using for example, MULTI_LINE WRITE.  But it seems auto-complete only works on keyboard entry. I've tried setting signal-all-changes and messing around with PREINPUT and forcing focus onto the control and so forth, but no luck.

Can autocomplete be made to work without direct keyboard entry? If so, sample code showing how please?

Thx!

11
Programming / Programmatic Auto-Complete
« on: July 27, 2023, 01:24:47 PM »
I have a multi-line control with 'Autocomplete defined that works great. What I would like to do is have Nomads auto-complete open when I programmatically assign values to the control, using for example, MULTI_LINE WRITE.  But it seems auto-complete only works on keyboard entry. I've tried setting signal-all-changes and messing around with PREINPUT and forcing focus onto the control and so forth, but no luck.

Can autocomplete be made to work without direct keyboard entry? If so, sample code showing how please?

Thx!

12
Nomads / Re: Possible Nomads Variable Values
« on: July 25, 2023, 11:52:18 AM »
Thank you, that's exactly what I was looking for.  Only question I have is I thought # indicated a numeric multi-line, but that is not shown in the OPT= table.

13
Nomads / Possible Nomads Variable Values
« on: July 24, 2023, 03:37:26 PM »
Is it documented anywhere what the possible values for Nomads variables can be? For example, I have seen that "L" in OBJ_STS$ indicates a multi-line control is Locked, but what are all the possible values for OBJ_STS? Guess it could be nice to know (or understand) that OBJ_HOTKEY$ is a timestamp sometimes (in the panel/lib default record) and that a numeric mask is stored in the OBJ_TXT$ field. Does a "#" in OBJ_STS$ for a multi-line indicate the 'numeric' option was selected?

14
Language / Re: TCB(44) Always a Positive Number?
« on: July 10, 2023, 02:03:58 PM »
Thx, Allen!

15
Language / TCB(44) Always a Positive Number?
« on: July 10, 2023, 01:17:01 PM »
Here in Utah the value of TCB(44) is 21600, or 6 hours. Applying TCB(45) for DST I get 7 hours, but this number is positive and my GMT is actually -7. Since I am not in a GMT-0 thru GMT+12 zone and cannot test this, does TCB(44) return negative for those time zones between Greenwich and the International Date Line?

Pages: [1] 2