Search found 27 matches

by Gukalov
26 Apr 2019 15:23
Forum: Visual Prolog
Topic: Color background of standard control
Replies: 3
Views: 1257

Re: Color background of standard control

Hi everybody.
In the similar situation I stupidly used imageControl (instead of staticTextControl)
with the set of image files to change the colors and inscriptions (ImageControl:setImageFile(FileName)).
by Gukalov
5 Jan 2019 9:44
Forum: Visual Prolog
Topic: Send to Background-Bring to Top
Replies: 17
Views: 7133

Re: Send to Background-Bring to Top

Look at "window.i": predicates setActive : (). predicates bringToTop : (). predicates forceToTop : (). For working with vpi there are: predicates tryGetVpiWindow : () -> vpiDomains::windowHandle VpiWindowHandle determ. predicates getVpiWindow : () -> vpiDomains::windowHandle VpiWindowHandle.
by Gukalov
16 Aug 2018 12:34
Forum: Visual Prolog
Topic: ListviewControl compilation 32bit vs 64 bit, VP8
Replies: 7
Views: 5405

Re: ListviewControl compilation 32bit vs 64 bit, VP8

I would try withou varM... clauses sssToItemList(SSS, StartingIndex) = ItemList :- % CurrX = varM::new(StartingIndex), ItemList = [ Item || list::memberIndex_nd(SS, Index, SSS), ItemID = uncheckedConvert(listViewControl::itemID, Index + StartingIndex /*+0*/), % <== e504 error here on 64bit compilati...
by Gukalov
26 Jul 2018 13:11
Forum: Visual Prolog
Topic: Edit pdf document
Replies: 5
Views: 5240

Re: Edit pdf document

Harrison Pratt wrote:
26 Jul 2018 12:57
Do you mean add text from a VIP application?
- Yes, exactly. It need to sign a lot of scans, and I'm too lazy to do it manually)))
by Gukalov
26 Jul 2018 12:16
Forum: Visual Prolog
Topic: Edit pdf document
Replies: 5
Views: 5240

Edit pdf document

Hi)))
How to add simple text label to pdf document?
by Gukalov
3 Aug 2017 16:11
Forum: Visual Prolog
Topic: Difference between "in" and isMember/2 ?
Replies: 4
Views: 1587

Hi. "in" can be used instead of list::getMember_nd/1 and etc... implement main open core, console clauses run() :- List = [ 1, 2, 3, 4, 5 ], foreach X in List do write(X, " ") end foreach, nl, nl, foreach Y in setM_redBlack::new(List) do write(Y, " ") end foreach, write("\n.............................
by Gukalov
27 May 2017 20:44
Forum: Visual Prolog
Topic: Delete a group of text files
Replies: 4
Views: 1778

Code: Select all

directory::forAllFiles(FullDirName, {(F) :- file::delete(F)}, "*.txt", false)
by Gukalov
7 Mar 2017 21:05
Forum: Visual Prolog
Topic: Visual Prolog : Edit Control : Check if string contains numbers
Replies: 16
Views: 5364

Harrison, what about "Ctrl+V"?!
Looks like your code doesn't check what user pastes with Ctrl+V.
And user ain't happy if pasting prohibitted at all.
Isn't it?
by Gukalov
7 Mar 2017 18:25
Forum: Visual Prolog
Topic: Visual Prolog : Edit Control : Check if string contains numbers
Replies: 16
Views: 5364

Simplier to delete spaces before checking:
if string:hasAlpha(string::replaceAll(Control:getText(), " ", "")) then

But to check if entering name is correct you need something more sirious than just letters&spaces)))
"A m o d Go kh ale" ?!)))
by Gukalov
7 Mar 2017 17:28
Forum: Visual Prolog
Topic: Visual Prolog : Edit Control : Check if string contains numbers
Replies: 16
Views: 5364

Ups)))
sorry
Just
if string:hasAlpha(Control:getText()) then
by Gukalov
7 Mar 2017 17:00
Forum: Visual Prolog
Topic: Visual Prolog : Edit Control : Check if string contains numbers
Replies: 16
Views: 5364

As you did before:
clauses
validateNumber(Control) =
if _ = string:hasAlpha(Control:getText()) then
control::contentsOk
else
control::contentsInvalid(Control, Control, string::format("%s must be ???", Control:getText()))
end if.
by Gukalov
7 Mar 2017 16:25
Forum: Visual Prolog
Topic: Visual Prolog : Edit Control : Check if string contains numbers
Replies: 16
Views: 5364

Re: Visual Prolog : Edit Control : Check if string contains numbers

Hi.
Amod Gokhale wrote: Is there example to validate if string contains only alphabets and message user if it contains numbers?
Class string

Code: Select all

predicates     hasAlpha : (string Source) determ.     % @short Succeds if #Source only contains alphabetic characters.
It's not enough?
by Gukalov
20 Jan 2017 2:01
Forum: Visual Prolog
Topic: Problem reading large VIP 5.2 database file as text strings
Replies: 7
Views: 2137

Hi.

flush may be...

Code: Select all

foreach     IS:repeatToEndOfStream(),     S = IS:readLine(),     frontToken(S,_Tok,_) do             OS:write(S,"\n"),     OS:flush() end foreach,
by Gukalov
1 Aug 2016 12:52
Forum: Visual Prolog
Topic: Using of the help button of the titlebar
Replies: 10
Views: 4939

Re: The contradicting arguments, display and working of the frame decoration

Ferenc Nagy wrote: 3) They inactivate the helpButton.
If helpResponer is set key "F1" works both with and without helpButton on titleBar. And without titleBar at all "F1" works.
It's almost good, it's good enough ;)
by Gukalov
29 Jul 2016 20:20
Forum: Visual Prolog
Topic: Using of the help button of the titlebar
Replies: 10
Views: 4939

Re: Minimize and maximize buttons do not allow to appear the help button

Ferenc Nagy wrote:Hi Gukalov,
Try to add to the setDecoration call these Buttons.
...
:-) The Help button will disappear.
Of course I tried))) And tried some years ago already)))
Why is it like that ask Thomas)))