Re: [BLACKBOX] Opening an embedded form view

From: Campbell, Robert (SELEX GALILEO, UK) <robert.d.campbell{([at]})nowhere.xy>
Date: Tue, 8 Dec 2009 09:43:00 -0000

----boundary-LibPST-iamunique-162597316_-_-
Content-type: text/plain

Doug

I am not sure I understand your question, but if I am correct
I can give an example:

1 - Download subsystem Lib from Component Pascal Collections.
2 - Open the file \Mod\LibDemoPlots.odc
3 - Click on <Ctrl>Q LibDemoPlots.DemoMap near the bottom of the file,
which should open as new Window.
4 - Put the curser onto the main coloured region.
5 - Click on the 'Edit' Tool near the bottom of the plot (* while
holding the Ctrl key *).

You should have a Form called a Palette Editor.

If you drag the 'curtains' in the 'Twin Sliders' in the Form the graph
should update interactively.

The Twin Sliders are custom Controls. The graph is a custom View, but
not a Control.

Is this an example of what you want?

If so, the means of doing it is in the (large) file
\\Lib\Mod\Plotters.odc.

If this is relevant, please feel free to come back with specific
questions.

Cheers

Robert

>> -----Original Message-----
>> From: BlackBox [mailto:BLACKBOX{([at]})nowhere.xy
>> Of Douglas G. Danforth
>> Sent: 08 December 2009 07:45
>> To: BLACKBOX{([at]})nowhere.xy
>> Subject: [BLACKBOX] Opening an embedded form view
>>
>> *** WARNING ***
>>
>> This message has originated outside your organisation,
>> either from an external partner or the Global Internet.
>> Keep this in mind if you answer this message.
>>
>> Folks,
>>
>> I still don't quite understand the process of embedding a
>> view in a form. The view I want will display a graph that
>> will change dynamically depending upon other variables
>> specified in the form.
>>
>> I can create a control (ala Ctrls module) and can deposit
>> and paste it into a form. I can drag the edges of the
>> view(?)/control(?) and make it the size I want. I can save the form.
>>
>> (1)
>> Now, to what should the control be linked?
>> In the Form User Manual it says
>>
>> "Each control can be linked to a variable, more exactly to
>> the field of a globally declared record variable, a
>> so-called interactor. "
>>
>> Ah, does this mean that my declared control is distinctly
>> different from "the field of a globally declared record
>> variable"? Does that mean that I do *not* put myView into a
>> field of the control but rather into the globally declared
>> record variable?
>>
>> (2)
>> So now, let us say that I have linked the control to the
>> correct variable and in my case it is a view. I assume that
>> before the control is allocated in the form (when the form
>> is first opened) that myView must already be created, i.e.
>> NEW(myView), right? That I (think) I can do. It depends
>> upon the order that the control is accessed. If MyModule
>> contains myView and fields in the form access variables in
>> MyModule then I assume when the form is opened that (I hope)
>> MyModule will be brought into memory BEFORE any attempt is
>> made to access the controls in the form. If so then in the
>> BEGIN Init END MyModule. statement I can initialize myView.
>> If however, the controls of the form are first initialized
>> before MyModule is loaded then I see no way to make this
>> work. Which way does it happen?
>>
>> (3)
>> So now, assume that myView has been created correctly and
>> that the form is happy and could find a non NIL myView. Who
>> opens myView?
>> If I open myView then the size of the view, say, 256x256,
>> may not correspond to the size of the view(?)/control(?)
>> that I manually dragged and expanded to a nice size in the
>> form. I really don't want to handle messages sent to the
>> form and back to query what the actual size of the view may
>> be. Is this what is necessary? Who opens the view?
>>
>> (4)
>> Scanning the views in a form looking for myView: I have
>> tried to use FormViews.Focus() when I press a button in the
>> form but it always comes back NIL. If I had that focus I
>> could step through the views and check to see if view IS
>> MyView and get its handle BUT I don't really understand
>> this. Who owns (controls) the view? When the control was
>> pasted into the form is the view, myView's pointer somehow
>> saved along with all of its fields in the form OR is nothing
>> of myView retained and only access via the 'metaprogramming'
>> features of BlackBox when the control is opened?
>>
>> Ok, folks, much help needed here.
>>
>> -Doug Danforth
>>
>>
>>
>> ---- To unsubscribe, send a message with body "SIGNOFF
>> BLACKBOX" to LISTSERV{([at]})nowhere.xy
>>
SELEX Sensors and Airborne Systems Limited
Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 3EL
A company registered in England & Wales. Company no. 02426132
********************************************************************
This email and any attachments are confidential to the intended
recipient and may also be privileged. If you are not the intended
recipient please delete it from your system and notify the sender.
You should not copy it or use it for any purpose nor disclose or
distribute its contents to any other person.
********************************************************************


----
To unsubscribe, send a message with body "SIGNOFF BLACKBOX" to LISTSERV{([at]})nowhere.xy----boundary-LibPST-iamunique-162597316_-_-
Content-type: application/rtf
Content-transfer-encoding: base64
Content-Dis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gJiBXYWxlcy4gIENvbXBhbnkgbm8uIDAyNDI2
MTMyXHBhcg0KKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioq
KioqKioqKioqKioqKioqKioqKipccGFyDQpUaGlzIGVtYWlsIGFuZCBhbnkgYXR0YWNobWVudHMg
YXJlIGNvbmZpZGVudGlhbCB0byB0aGUgaW50ZW5kZWRccGFyDQpyZWNpcGllbnQgYW5kIG1heSBh
bHNvIGJlIHByaXZpbGVnZWQuIElmIHlvdSBhcmUgbm90IHRoZSBpbnRlbmRlZFxwYXINCnJlY2lw
aWVudCBwbGVhc2UgZGVsZXRlIGl0IGZyb20geW91ciBzeXN0ZW0gYW5kIG5vdGlmeSB0aGUgc2Vu
ZGVyLlxwYXINCllvdSBzaG91bGQgbm90IGNvcHkgaXQgb3IgdXNlIGl0IGZvciBhbnkgcHVycG9z
ZSBub3IgZGlzY2xvc2Ugb3JccGFyDQpkaXN0cmlidXRlIGl0cyBjb250ZW50cyB0byBhbnkgb3Ro
ZXIgcGVyc29uLlxwYXINCioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioq
KioqKioqKioqKioqKioqKioqKioqKioqKioqXHBhcg0KXHBhcg0KXHBhcg0KLS0tLVxwYXINClRv
IHVuc3Vic2NyaWJlLCBzZW5kIGEgbWVzc2FnZSB3aXRoIGJvZHkgIlNJR05PRkYgQkxBQ0tCT1gi
IHRvIExJU1RTRVJWQExJU1RTLk9CRVJPTi5DSH19AAngKPA
----boundary-LibPST-iamunique-162597316_-_---
Received on Tue Dec 08 2009 - 10:43:00 UTC

This archive was generated by hypermail 2.3.0 : Thu Sep 26 2013 - 06:30:39 UTC