Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Invalid tab in combo box
#1
hello everyone,

In the following example, I want to use tab to align characters, But it No effect,

Does anyone know what the problem is? Thanks in advance

[Image: pic.png]



Macro Macro4
Code:
Copy      Help
_s=
;ke-48=text0
;cm-291=text6
;win-26=test8
;wib-262=test7
;ww-28=test4

ARRAY(str) a=_s

for int'i 0 numlines(_s)
,a[i].findreplace("-" "[9]")
,a[i].findreplace("=" "[9]")
,out a[i]

str s=a

str dd=
;BEGIN DIALOG
;0 "" 0x90C80AC8 0x0 0 0 224 136 "Dialog" "4"
;3 ComboBox 0x54230641 0x0 12 8 96 114 ""
;1 Button 0x54030001 0x4 116 116 48 14 "OK"
;2 Button 0x54030000 0x4 168 116 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2040A00 "*" "" "" ""

str controls = "3"
str cb3
cb3=s
if(!ShowDialog(dd 0 &controls)) ret
#2
Combo box does not support it. Unless you custom draw, but it is not so easy.

WPF combo box supports tabs and multiple lines.
Example in QM3:
C# code:
var b = new AWpfBuilder("Window").WinSize(400);
b.R.Add("Combo", out ComboBox combo1).Items("Zero|\tOne|T\nwo");
b.End();
if (!b.ShowDialog()) return;
#3
Thanks for your advice. I found a small problem

Control information is hidden. It's not convenient to use the mouse wheel. I can only change the height

recommended to display the control information in two columns. The second column displays the control information, which is consistent with qm2

In addition, pressing Alt + F8 not output the details

[Image: err.png]
#4
In next QM3 version, mouse info will be in 3 lines. Or 4-5 when wraps lines.

Alt+F8 probably will not be added. To copy text: click, move the mouse somewhere, press Ctrl+A+C.
#5
@Gintaras

Alt+F8 probably will not be added. To copy text: click, move the mouse somewhere, press Ctrl+A+C.
__________________________________________________________________________________________
It can't be realized. In qm2, ALT + F8 can be implemented

because, When I move the mouse, the information of the control and window has changed

Or need other operations? Huh
#6
I want to use underscores, realization similar Tab alignment effect
[Image: 1.png]

This needs to determine the number of letters and numbers

control the number of underscores

What functions need to use?

Or is there any other similar solution? Any suggestions are welcome. Thanks in advance


I can use the following method(Add space) to achieve the effect of alignment in JAVA
How to realize it in qm2?

System.out.printf("%10s%10s%10s",s1,s2,s3);


Macro add tab
Code:
Copy      Help
s=
;ke-48=text0
;cm-291=text6
;win-26=test8
;wib-262=test7
;ww-28=test4

ARRAY(str) a=_s

for int'i 0 numlines(_s)
,a[i].findreplace("-" "__")
,a[i].findreplace("=" "__")
,out a[i]

str s=a

str dd=
;BEGIN DIALOG
;0 "" 0x90C80AC8 0x0 0 0 224 136 "Dialog" "4"
;3 ComboBox 0x54230641 0x0 12 8 96 114 ""
;1 Button 0x54030001 0x4 116 116 48 14 "OK"
;2 Button 0x54030000 0x4 168 116 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2040A00 "*" "" "" ""

str controls = "3"
str cb3
cb3=s
if(!ShowDialog(dd 0 &controls)) ret

#7
Quote:When I move the mouse, the information of the control and window has changed
1. Click the Info panel. Now QM3 window is active, and the Info panel is focused, with caret.
2. Move the mouse to the object and stop.
3. Ctrl+A+C.
#8
Macro Macro3099
Code:
Copy      Help
str s1="one"
str s2="two"
str s3="three"
str s.format("%10s%10s%10s",s1,s2,s3)
out s


Forum Jump:


Users browsing this thread: 1 Guest(s)