str2codelines

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - Text/Strs/Chars/Links
Introduced first in SolidGeometry 4.6, Creation date: 2019-05-10, Last change: 2025-09-14

creates from long string, several lines that can be used as matlab code



See Also: SGofCPLcommand , fprintfvec2 , fprintfvec , sprintfvec

Example Illustration

 missing image of str2codelines(Str,ll,fle)

Syntax

[clstr]=str2codelines(Str,[ll,fle])

Input Parameter

Str: string to break into lines
ll: maximum length of line
fle: reduced number of chars if 1st line or string

Output Parameter

[clstr]: String broken into code lines

Examples


str2codelines(['The quick brown fox ',...
'jumps over the lazy dog'],10)
str2codelines(['b 5 5,h 4.5,roty 90,move -4.5 0 0,save B,enter,b 3 5,enter,d 5 1.5 0,+,h',...
' 1.5,save A,move 1.5 0 -2.5,dups 1 1 2 2,+,enter,d 2.5 3 0,h 10,move 0 0',...
' -5,-,enter,load A,rotz 180,move 4.5 0 -'])




Copyright 2019-2025 Tim C. Lueth. All rights reserved. The code is the property of Tim C. Lueth and may not be redistributed or modified without explicit written permission. This software may be used free of charge for academic research and teaching purposes only. Commercial use, redistribution, modification, or reverse engineering is strictly prohibited. Access to source code is restricted and granted only under specific agreements. For licensing inquiries or commercial use, please contact: Tim C. Lueth

Last html export of this page out of FM database by TL: 2025-09-21