Category : Files from Magazines
Archive   : MAR93.ZIP
Filename : CDA.ASC
by Lowell Williams
[LISTING ONE]
/* specify the page in the document */
setup_subtitle_page 1
{
/* Change the color to black and font to helvetica */
status = hlr_set_color (3)
status = font (0)
/* Turn on highlighting and underlining */
status = hlr_set_text_rendition(hlr_c-highlight);
status = hlr_set_text_rendition(hlr_c-underline);
/* draw a page title */
status = hlr_draw_text{
1800, /* upper left x */
12500 /* upper left y */
1200*5 /* line length */
300 /* text height */
RSAMPLE TEST - continued R, /* text string */
hlr_c_text_center /* center text */
};
}
[LISTING TWO]
{
/* Set the line width */
status = hlr_set_line_width (25)
/* draw three rectangles */
status = hlr_draw_rectangle (3600, 8000, 5200, 9700);
status = hlr_draw_rectangle (3800, 8400, 5400, 10000);
status = hlr_draw_rectangle (4000, 8800, 5600, 10400);
return;
}
[LISTING THREE]
i = 0
status = define_galls (galls4, "gal0", i, 1200, 10800, 8400, 12000, "gal1",
hlr_c_default, hlr_c_no_border_on);
status = define_galls (galls4, "gal1", ++i, 1200, 5500, 3600, 7000, "gal",
hlr_c_default, hlr_c_no_border_on);
status = define_galls (galls4, "gal2", ++i, 3601, 5500, 6000, 7000, "gal3",
hlr_c_default,hlr_c_no_border_on);
status = define_galls (galls4, "gal3", ++i, 5*1201, 5500, 7*1200, 7000, "gal4",
hlr_c_default, hlr_c_no_border_on);
status = define_galls (galls4, "gal4", ++i, 1201, 4000, 3600, 5500, "gal5",
hlr_c_default,hlr_c_no_border_on);
status = define_galls (galls4, "gal5", ++i, 3*1201, 4000, 5*1200, 5500, "gal6",
hlr_c_default, hlr_c_no_border_on);
status = define_galls (galls4, "gal6", ++i, 5*1201, 4000, 7*1200, 5500, "gal7",
hlr_c_default, hlr_c_no_border_on);
status = define_galls (galls4, "gal7", ++i, 1201, 2500, 3600, 4000, "gal",
hlr_c_default, hlr_c_no_border_on);
status = define_galls (galls4, "gal8", ++i, 3*1201, 2500, 5*1200, 4000, "gal9",
hlr_c_default, hlr_c_no_border_on);
status = define_galls (galls4, "gal9", ++i, 5*1201, 2500, 7*1200, 4000,"gal5a",
hlr_c_default, hlr_c_no_border_on);
[LISTING FOUR]
int create_page_1
status = hlr_set_galley (4,0)
status = hlr_set_paragraph (2);
status = hlr_write_text ("this is the first paragraph of the first galley
containing the first flow for this sample program. ");
status = hlr_write_text ("The text is justified and is displayed above the
path-based text that is displayed above the table.");
status = hlr_set_new_ galley(1)
status = hlr_set_paragraph (2);
for (i=1; i < 9; i++) {
sprintf (temp1 , "%s%d%s", "This is flow ",i,". ");
status = hlr_write_text (temp1);
/* change galleys */
if (i < 9)
status = hlr_set_new_galley (1)
status = hlr_set_paragraph (2)
}
Example 1: Examples of DDIF primitives
(a)
aggregate_item = DDIF$_TXT_CONTENT
status = CdaStoreItem ( root_aggregate-handle
aggregate_handle_stack[ahs_index],
aggregate_item,
txt_content_length,
txt_content,
0, 0)
(b)
aggregate_type = DDIF$_TXT;
status = CdaCreateAggregate ( root_aggregate_handle,
aggregate_type,
&aggregate_handle_stack[ahs_index]
(c)
aggregate_item = DDIF$_SGA_FRM_POSITION_C:
integer_value = DDIF$K_FRAME_GALLEY;
status = CdaStoreItem ( root_aggregate_handle
aggregate_handle_stack[ahs_index],
aggregate_item,
integer_length,
& integer_value,
0, 0)
(d)
aggregate_type = DDIF$_SGA;
status = CdaCreateAggregate ( root_aggregate-handle
aggregate_handle_stack[ahs_index],
aggregate_item = DDIF$_TYD_ATTRIBUTES;
status = CdaStoreItem ( root_aggregate_handle
aggregate_handle_stack[ahs_index-1],
aggregate_item,
aggregate_handle_length,
& aggregate_handle_stack[ahs_index],
0, 0)
Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!
This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.
But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/