<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How do add text to a cell that has an image loaded? in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513687#M74113</link>
    <description>&lt;P&gt;...and the orange background is because those images have transparent pixels. Your images probably don't have transparent pixels, so you probably won't see that. Preserving the transparency while adding text is a lot harder.&lt;/P&gt;</description>
    <pubDate>Fri, 24 Jun 2022 13:49:01 GMT</pubDate>
    <dc:creator>Craige_Hales</dc:creator>
    <dc:date>2022-06-24T13:49:01Z</dc:date>
    <item>
      <title>How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/510961#M73913</link>
      <description>&lt;P&gt;Is it possible to add text to a cell that has already loaded images?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2022-06-20_17-48-10.png" style="width: 397px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/43403i461809A77D341E7F/image-size/large?v=v2&amp;amp;px=999" role="button" title="2022-06-20_17-48-10.png" alt="2022-06-20_17-48-10.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 17:01:49 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/510961#M73913</guid>
      <dc:creator>lwx228</dc:creator>
      <dc:date>2023-06-09T17:01:49Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/510972#M73914</link>
      <description>&lt;P&gt;You could use set each value to re-create the image with text&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Big Class Families.jmp");


Column(dt, "picture") &amp;lt;&amp;lt; Set Each Value(
	H List Box(align("center"),
		Text box(:name),
		:picture
	) &amp;lt;&amp;lt; Get Picture
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 20 Jun 2022 14:16:56 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/510972#M73914</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2022-06-20T14:16:56Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/510993#M73916</link>
      <description>&lt;P class=""&gt;&lt;SPAN class=""&gt;If I want to add more than one cell of text, I try to add it left and right.&lt;/SPAN&gt;&lt;/P&gt;&lt;P class=""&gt;&lt;SPAN class=""&gt;Can I add text below?&lt;/SPAN&gt;&lt;SPAN class=""&gt;It looks like this down here.&lt;/SPAN&gt;&lt;/P&gt;&lt;P class=""&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Column(dt, "picture") &amp;lt;&amp;lt; Set Each Value(
	H List Box(align("center"),
		Text box(:name),
		:picture
	) &amp;lt;&amp;lt; Get Picture
);
Column(dt, "picture") &amp;lt;&amp;lt; Set Each Value(
	H List Box(align("center"),
		Text box(:sports),
		:picture
	) &amp;lt;&amp;lt; Get Picture
);&lt;/CODE&gt;&lt;/PRE&gt;&lt;P class=""&gt;&lt;SPAN class=""&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2022-06-20_22-33-43.png" style="width: 176px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/43404i96ECAFB55B8BEC7E/image-size/large?v=v2&amp;amp;px=999" role="button" title="2022-06-20_22-33-43.png" alt="2022-06-20_22-33-43.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class=""&gt;Thanks Experts!&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jun 2022 14:38:13 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/510993#M73916</guid>
      <dc:creator>lwx228</dc:creator>
      <dc:date>2022-06-20T14:38:13Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/511002#M73917</link>
      <description>&lt;P&gt;Using proper &lt;A href="https://www.jmp.com/support/help/en/16.2/#page/jmp/display-functions.shtml" target="_blank" rel="noopener"&gt;display functions&lt;/A&gt; (h list box, v list box, lineup box...) and &lt;A href="https://www.jmp.com/support/help/en/16.2/#page/jmp/display-boxes.shtml" target="_blank" rel="noopener"&gt;display boxes&lt;/A&gt; should help you to organize the elements&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jun 2022 14:55:50 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/511002#M73917</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2022-06-20T14:55:50Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/512989#M74046</link>
      <description>&lt;P&gt;JSL can add text to a screenshot and then place it on the image.&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = Open( "$SAMPLE_DATA/Big Class Families.jmp" );
rp = New Window( "", dt &amp;lt;&amp;lt; Get As Report );
rp &amp;lt;&amp;lt; Set Cell Height( 250 );
pic = rp &amp;lt;&amp;lt; Get Picture;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2022-06-23_21-48-20.png" style="width: 464px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/43506i9AAC3775BFEA739C/image-size/large?v=v2&amp;amp;px=999" role="button" title="2022-06-23_21-48-20.png" alt="2022-06-23_21-48-20.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 23 Jun 2022 14:25:59 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/512989#M74046</guid>
      <dc:creator>lwx228</dc:creator>
      <dc:date>2022-06-23T14:25:59Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513381#M74087</link>
      <description>&lt;P&gt;&lt;LI-MESSAGE title="Add Text to a Picture" uid="513376" url="https://community.jmp.com/t5/Uncharted/Add-Text-to-a-Picture/m-p/513376#U513376" discussion_style_icon_css="lia-mention-container-editor-message lia-img-icon-blog-thread lia-fa-icon lia-fa-blog lia-fa-thread lia-fa"&gt;&lt;/LI-MESSAGE&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Use a graphics frame box to add text and lines on top of a picture." style="width: 312px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/43538i73CF3F31DACC78C8/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Use a graphics frame box to add text and lines on top of a picture." /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Use a graphics frame box to add text and lines on top of a picture.&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 23 Jun 2022 23:48:28 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513381#M74087</guid>
      <dc:creator>Craige_Hales</dc:creator>
      <dc:date>2022-06-23T23:48:28Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513670#M74105</link>
      <description>&lt;P&gt;Thank Craige!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I copied the following JSL, just to achieve the simplest function.&lt;BR /&gt;But I still don't know the code.Text is not added where it should be.&lt;BR /&gt;Consult experts to help modify, with the simplest code implementation.&lt;/P&gt;&lt;P&gt;Thanks Experts!&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = Open( "$SAMPLE_DATA/Big Class Families.jmp" );
dt &amp;lt;&amp;lt; delete columns( 3 :: N Col( dt ) );
dt &amp;lt;&amp;lt; delete rows( 6 :: N Row( dt ) );
dt &amp;lt;&amp;lt; Set Cell Height( 100 );
rp = New Window( "", dt &amp;lt;&amp;lt; Get As Report );
original = rp &amp;lt;&amp;lt; Get Picture;
{xSize, ySize} = original &amp;lt;&amp;lt; size;

gb = Graph Box(
	&amp;lt;&amp;lt;backgroundcolor( "orange" ),
	FrameSize( xSize + 1, ySize + 1 ),
	X Scale( 0, xSize + 1 ),
	Y Scale( 0, ySize + 1 ),
	&amp;lt;&amp;lt;Add Image( image( original ), bounds( top( 0 ), Left( 1 ), bottom( ySize ), Right( xSize + 1 ) ) ),
	Text( Center Justified, { 50, 10}, "KATIE" )
);
updated = gb[framebox( 1 )] &amp;lt;&amp;lt; getpicture;
updated &amp;lt;&amp;lt; crop( Left( 1 ), top( 1 ), Right( xSize + 1 ), bottom( ySize + 1 ) );
originalMatrix = original &amp;lt;&amp;lt; getpixels;
newMatrix = updated &amp;lt;&amp;lt; getpixels;
diff = (originalMatrix - newMatrix != 0);
New Window( "bitmaps", V List Box( gb ) );&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2022-06-24_21-03-11.png" style="width: 327px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/43543iCBAAA1AF65C77AF3/image-size/large?v=v2&amp;amp;px=999" role="button" title="2022-06-24_21-03-11.png" alt="2022-06-24_21-03-11.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jun 2022 13:09:38 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513670#M74105</guid>
      <dc:creator>lwx228</dc:creator>
      <dc:date>2022-06-24T13:09:38Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513671#M74106</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Text( Center Justified, { 50, 10}, "KATIE" )&lt;/CODE&gt;&lt;/PRE&gt;&lt;UL&gt;&lt;LI&gt;&lt;P class=""&gt;How can this code be modified to fit inside the original image?&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;</description>
      <pubDate>Fri, 24 Jun 2022 13:11:32 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513671#M74106</guid>
      <dc:creator>lwx228</dc:creator>
      <dc:date>2022-06-24T13:11:32Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513675#M74107</link>
      <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="text size function; 5 points is a little too small for my eyes." style="width: 798px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/43544i68F7009620776414/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="text size function; 5 points is a little too small for my eyes." /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;text size function; 5 points is a little too small for my eyes.&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jun 2022 13:20:59 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513675#M74107</guid>
      <dc:creator>Craige_Hales</dc:creator>
      <dc:date>2022-06-24T13:20:59Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513679#M74109</link>
      <description>&lt;P&gt;Wait. You are using a picture of the whole data table, but I'm pretty sure you want to work on one picture at a time.&lt;/P&gt;
&lt;P&gt;Just grab the image from dt:picture[iRow] rather than loading it from a file, then replace it when done. Approximately like this:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;original = dt:picture[iRow];
...existing jsl...
dt:picture[iRow] = updated;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 24 Jun 2022 13:29:55 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513679#M74109</guid>
      <dc:creator>Craige_Hales</dc:creator>
      <dc:date>2022-06-24T13:29:55Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513681#M74110</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = Open( "$SAMPLE_DATA/Big Class Families.jmp" );
For( iRow = 1, iRow &amp;lt;= N Rows( dt ), irow += 1, 
// open the original
	original = dt:picture[iRow];
	{xSize, ySize} = original &amp;lt;&amp;lt; size;
// use a frame to do the drawing, make the original fit the frame exactly
	gb = Graph Box(
		&amp;lt;&amp;lt;backgroundcolor( "orange" ), // to see errors better
		FrameSize( xSize + 1, ySize + 1 ), // the +1 is required, 4 times
		X Scale( 0, xSize + 1 ),
		Y Scale( 0, ySize + 1 ), 
	// apparently x and y are different. this is correct in 17EA.
		&amp;lt;&amp;lt;Add Image( image( original ), bounds( top( 0 ), Left( 1 ), bottom( ySize ), Right( xSize + 1 ) ) ), 
	// draw something on top of the image
		Text( Center Justified, {xSize / 2, 10}, dt:name[irow] );
	);
// capture an updated image
	updated = gb[framebox( 1 )] &amp;lt;&amp;lt; getpicture;
// crop added border. "updated" is the final image.
	updated &amp;lt;&amp;lt; crop( Left( 1 ), top( 1 ), Right( xSize + 1 ), bottom( ySize + 1 ) );
	dt:picture[irow]=updated;
);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Mug shots" style="width: 776px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/43545i3203F35A9995F604/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Mug shots" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Mug shots&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jun 2022 13:35:48 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513681#M74110</guid>
      <dc:creator>Craige_Hales</dc:creator>
      <dc:date>2022-06-24T13:35:48Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513685#M74112</link>
      <description>&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;I see!&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2022-06-24_21-45-24.png" style="width: 734px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/43546i5D9CE2769F444ED8/image-size/large?v=v2&amp;amp;px=999" role="button" title="2022-06-24_21-45-24.png" alt="2022-06-24_21-45-24.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jun 2022 13:46:51 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513685#M74112</guid>
      <dc:creator>lwx228</dc:creator>
      <dc:date>2022-06-24T13:46:51Z</dc:date>
    </item>
    <item>
      <title>Re: How do add text to a cell that has an image loaded?</title>
      <link>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513687#M74113</link>
      <description>&lt;P&gt;...and the orange background is because those images have transparent pixels. Your images probably don't have transparent pixels, so you probably won't see that. Preserving the transparency while adding text is a lot harder.&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jun 2022 13:49:01 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-do-add-text-to-a-cell-that-has-an-image-loaded/m-p/513687#M74113</guid>
      <dc:creator>Craige_Hales</dc:creator>
      <dc:date>2022-06-24T13:49:01Z</dc:date>
    </item>
  </channel>
</rss>

