Search found 20 matches

by andyhill
Tue Jan 04, 2011 1:11 am
Forum: Support
Topic: Pre Scale Image During Insert ?
Replies: 10
Views: 30953

Sergey, I have used my real code (not mockup) and ask for help with:-

1) Scaling images 50% of paper/orientation selection (rve2 image table has 2 cells) with aspect ratio preserved

2) Inserting RVF streams (from Unicode DB) into rve2 notes table

procedure TfRichView.Print1Click(Sender: TObject ...
by andyhill
Mon Jan 03, 2011 8:36 pm
Forum: Support
Topic: Need TableSizeRV Feature (without RVActions)
Replies: 1
Views: 9876

Need TableSizeRV Feature (without RVActions)

Hi, RVActions provides a popup grid to select row/col size on table create.

My project does not use RVActions but I would like to emulate this feature.

Can you please show me how to add this feature to my project without using RVActions - Thanks.
by andyhill
Mon Jan 03, 2011 8:16 pm
Forum: Support
Topic: Help With UnDo
Replies: 2
Views: 11260

Help With UnDo

Hi, I cannot undo lines added by code below:-

rve.BeginUpdate;
rve.BeginUndoGroup(rvutMiscTyping); // Tried everything ???
rve.SetUndoGroupMode(True);

rve.AddNL('', CurTextStyleNo, CurParStyleNo);

rve.CurTextStyleNo:= TextStyleNo;
rve.CurParaStyleNo:= ParStyleNo;
rve.AddNL(DateStr ...
by andyhill
Mon Jan 03, 2011 7:33 pm
Forum: Support
Topic: Pre Scale Image During Insert ?
Replies: 10
Views: 30953

So if I need to add 30 images I need to have 30 Bitmap Objects ??? If this is so it seems cumbersome ???

I need the Table (100% of page) with 2 cells which would make the desired cell (50% of page) so Bitmap size should be scaled to cell width taking into account the aspect ratio (we have already ...
by andyhill
Sun Jan 02, 2011 9:32 pm
Forum: Support
Topic: Pre Scale Image During Insert ?
Replies: 10
Views: 30953

Thanks Sergey for your support, truly appreciated - however I have some issues (please look for ***):-

procedure TfRichView.Print1Click(Sender: TObject);
var
PrintIt: Boolean;
ClientName, s: String;
table: TRVTableItemInfo;
i, w: Integer;
ItemInfo: TCustomRVItemInfo;
//
bm: TBitmap;
RVData ...
by andyhill
Sat Jan 01, 2011 9:05 pm
Forum: Support
Topic: How Can I Build a Style Programatically ?
Replies: 6
Views: 21838

Insert RVF File into Table Cell Programatically

rve2.AddItem('MyTempTable', table);
//
for i:= 0 to rve2.TopLevelEditor.ItemCount -1 do begin
ItemInfo:= rve2.TopLevelEditor.GetItem(i);
if ItemInfo.ItemText = 'MyTempTable' then begin
ItemNo:= rve2.TopLevelEditor.GetItemNo(ItemInfo);
Offs:= rve2.TopLevelEditor.GetOffsBeforeItem(ItemNo);
rve2 ...
by andyhill
Sat Jan 01, 2011 7:59 pm
Forum: Support
Topic: How Can I Build a Style Programatically ?
Replies: 6
Views: 21838

Thank you Seregy.

You did not explain:-

1) How to add Bold Attribute to text style ?

2) How to select Text Attribute when using ADDNL ?

3) How to insert rv stream/file into table cell, either during table construction -or- locating table and cell in editor ?
by andyhill
Sat Jan 01, 2011 7:54 am
Forum: Support
Topic: How Can I Build a Style Programatically ?
Replies: 6
Views: 21838

Merge rve streams and files

function TfRichView.RVCopy(RVSource, RVDest: TCustomRichView): Boolean;
var
MyStream: TMemoryStream;
begin
try
MyStream:= TMemoryStream.Create;
try
RVSource.SaveRVFToStream(MyStream, False);
MyStream.Position:= 0;
Result:= RVDest.InsertRVFFromStream(MyStream, RVDest.ItemCount);
RVDest ...
by andyhill
Fri Dec 31, 2010 10:03 pm
Forum: Support
Topic: How Can I Build a Style Programatically ?
Replies: 6
Views: 21838

How Can I Build a Style Programatically ?

How Can I Build a Style Programatically and use when inserting line (need to use TextStyle with Bold Attribute) ?

rvs2.ResetTextStyles;
rvs2.ResetParaStyles;
//
rvs2.TextStyles.AddFont('Times New Roman', 12, clBlack, clWhite, [want bold]);
rvs2.ParaStyles.Add;
rvs2.ParaStyles[0].Alignment ...
by andyhill
Fri Dec 31, 2010 1:24 am
Forum: Support
Topic: RichEdit Print / PrintPreview - Append Virtual Lines
Replies: 2
Views: 16129

Inserting other rv data and rtf data would be good to.
by andyhill
Thu Dec 30, 2010 11:52 pm
Forum: Support
Topic: RichEdit Print / PrintPreview - Append Virtual Lines
Replies: 2
Views: 16129

RichEdit Print / PrintPreview - Append Virtual Lines

Hi, I have a need to Append Lines to the output on Print and PrintPreview but leave the original rve contents unchanged.

RVPrint1.AssignSource(rve);

add new lines here ?

RVPrint1.FormatPages(rvdoALL);

RVPrint1.Print('', 1, False);

Thanks
Andy
by andyhill
Thu Dec 30, 2010 9:24 pm
Forum: Support
Topic: Pre Scale Image During Insert ?
Replies: 10
Views: 30953

(1) Thanks, I feel rather silly missing that one

(2) I look forward to your example
by andyhill
Thu Dec 30, 2010 8:34 pm
Forum: Support
Topic: Pre Scale Image During Insert ?
Replies: 10
Views: 30953

Thanks Sergey,

1) My StrechDraw method will not compile (which unit must I put in the uses clause) ?

2) Can you show me code "display it scaled using trichview item properties" on insert where we constrain the size to the current table cell size ?

Thanks Again
by andyhill
Thu Dec 30, 2010 7:04 am
Forum: Support
Topic: Pre Scale Image During Insert ?
Replies: 10
Views: 30953

Pre Scale Image During Insert ?

Hi, Please advise how to pre scale image during insert ?

pic:= TPicture.Create;
try
pic.LoadFromFile(OpenDialog1.FileName);

bm:= TBitmap.Create;
bm.Height:= 100; // fudge value for testing
bm.Width:= 100; // fudge value for testing

ARect:= Rect(0, 0, bm.Height, bm.Width);
bm.Canvas ...
by andyhill
Wed Jun 14, 2006 11:26 pm
Forum: Support
Topic: PDF Import
Replies: 4
Views: 19305

Any ideas anyone ?