How to hide text in dwg file(just like abviewer)?
Moderators: SDS, support, admin
How to hide text in dwg file(just like abviewer)?
Hi
In Abviewer we can hide text(including the content of Dimension), how can I achieve it? Please give me some example code?
I'm testing it with VCLImport.
There's another question: how can I zoom and pan with left mouse key (just like autocad)?
Thank you
Thought that I found a powerfull CAD tool, keep on testing.....
In Abviewer we can hide text(including the content of Dimension), how can I achieve it? Please give me some example code?
I'm testing it with VCLImport.
There's another question: how can I zoom and pan with left mouse key (just like autocad)?
Thank you
Thought that I found a powerfull CAD tool, keep on testing.....
Hello,
<blockquote id="quote"><font size="2" face="Verdana, Arial, Helvetica" id="quote">quote:<hr height="1" noshade id="quote"> In Abviewer we can hide text(including the content of Dimension), how can I achieve it? Please give me some example code?<hr height="1" noshade id="quote"></font id="quote"></blockquote id="quote">
It is nesessray to use property TsgDXFImage.TextVisible: Boolean.
Set true to show texts.
Set false to hide texts.
<blockquote id="quote"><font size="2" face="Verdana, Arial, Helvetica" id="quote">quote:<hr height="1" noshade id="quote"> There's another question: how can I zoom and pan with left mouse key (just like autocad)? <hr height="1" noshade id="quote"></font id="quote"></blockquote id="quote">
The following code is taken from the Viewer demo (CADImportVCL: http://www.cadsofttools.com/download/cadimportvcl.zip). This demo is available in the ..\cadimportvcl\Delphi\Demos\Viewer\.. folder.
<b><u>Zoom</u></b>:
<b><u>Pan</u></b>:
It is nesessary to use Drag property of TsgImage object:
Enables or disables moving the picture in scroll window using right mouse button.
<b>property</b> Drag: Boolean;
Description
Default value is True. If Drag = False, you may not move the picture.
Moving is realized by pressing a mouse wheel or left mouse button and dragging.
Dmitry.
<blockquote id="quote"><font size="2" face="Verdana, Arial, Helvetica" id="quote">quote:<hr height="1" noshade id="quote"> In Abviewer we can hide text(including the content of Dimension), how can I achieve it? Please give me some example code?<hr height="1" noshade id="quote"></font id="quote"></blockquote id="quote">
It is nesessray to use property TsgDXFImage.TextVisible: Boolean.
Set true to show texts.
Set false to hide texts.
<blockquote id="quote"><font size="2" face="Verdana, Arial, Helvetica" id="quote">quote:<hr height="1" noshade id="quote"> There's another question: how can I zoom and pan with left mouse key (just like autocad)? <hr height="1" noshade id="quote"></font id="quote"></blockquote id="quote">
The following code is taken from the Viewer demo (CADImportVCL: http://www.cadsofttools.com/download/cadimportvcl.zip). This demo is available in the ..\cadimportvcl\Delphi\Demos\Viewer\.. folder.
<b><u>Zoom</u></b>:
Code: Select all
<b>procedure</b> TForm1.FormMouseWheelDown(Sender: TObject; Shift: TShiftState; MousePos: TPoint; <b>var</b> Handled: Boolean);
<b>begin
if</b> sgPaintBox.Empty <b>or</b> (PageControl1.ActivePage <> TabSheet1) <b>then</b> Exit;
MousePos := ScrollBox1.ScreenToClient(MousePos);
sgPaintBox.ChangeScale(False, 0.8, MousePos);
Handled := True;
<b>end</b>;
<b>procedure</b> TForm1.FormMouseWheelUp(Sender: TObject; Shift: TShiftState; MousePos: TPoint; <b>var</b> Handled: Boolean);
<b>begin
if</b> sgPaintBox.Empty <b>or</b> (PageControl1.ActivePage <> TabSheet1) <b>then</b> Exit;
MousePos := ScrollBox1.ScreenToClient(MousePos);
sgPaintBox.ChangeScale(False, 1.2, MousePos);
Handled := True;
<b>end</b>;
It is nesessary to use Drag property of TsgImage object:
Enables or disables moving the picture in scroll window using right mouse button.
<b>property</b> Drag: Boolean;
Description
Default value is True. If Drag = False, you may not move the picture.
Moving is realized by pressing a mouse wheel or left mouse button and dragging.
Dmitry.