// File: /workspace/github_c_makefile_star2_O3/enzo1982[P]smooth/tools/translator/translator.cpp
// Function: Translator::FormatLines(smooth::String const&)
Void Translator::FormatLines(const String &file)
{
	String::InputFormat	 inputFormat("UTF-8");
	String::OutputFormat	 outputFormat("UTF-8");

	IO::InStream	 in(IO::STREAM_FILE, file, IO::IS_READ);

	String		 xmlString;

	while (in.GetPos() < in.Size())
	{
		String	 line = in.InputLine();

		if (line.Trim().StartsWith("<section ")) xmlString.Append("\n");

		while (line.StartsWith("    "))	{ xmlString.Append("\t"); line = line.Tail(line.Length() - 4); }
		while (line.StartsWith(" "))	{ xmlString.Append("  "); line = line.Tail(line.Length() - 1); }

		xmlString.Append(line).Append("\n");
	}

	IO::OutStream	 out(IO::STREAM_FILE, file, IO::OS_REPLACE);

	out.OutputString(xmlString);

	out.Close();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x298, %rsp            # imm = 0x298
movq %rsi, %r14
leaq 0x2852(%rip), %rbx      # 0x12513
leaq 0x58(%rsp), %rdi
movq %rbx, %rsi
callq 0x107f4
leaq 0x40(%rsp), %rdi
movq %rbx, %rsi
callq 0x1083e
leaq 0x88(%rsp), %rdi
movl $0x3, %esi
movq %r14, 0x20(%rsp)
movq %r14, %rdx
movl $0x2, %ecx
callq 0x7400
leaq 0x28(%rsp), %rdi
xorl %esi, %esi
callq 0x7480
cmpw $0x0, 0x90(%rsp)
je 0xfee0
leaq 0x190(%rsp), %r14
leaq 0x8(%rsp), %r12
leaq 0x28(%rsp), %r15
leaq 0x2822(%rip), %rbp      # 0x12550
movq 0xd0(%rsp), %rax
cmpq 0x98(%rsp), %rax
jge 0xfeea
movq %r14, %rdi
leaq 0x88(%rsp), %rsi
callq 0x7750
movq %r12, %rdi
movq %r14, %rsi
callq 0x7970
leaq 0x70(%rsp), %r13
movq %r13, %rdi
leaq 0x27d5(%rip), %rsi      # 0x12543
callq 0x77f0
movq %r12, %rdi
movq %r13, %rsi
callq 0x77b0
movl %eax, %ebx
movq %r13, %rdi
callq 0x7980
movq %r12, %rdi
callq 0x7980
testb %bl, %bl
je 0xfdb6
movq %r12, %rdi
leaq 0x27a3(%rip), %rsi      # 0x12541
callq 0x77f0
movq %r15, %rdi
movq %r12, %rsi
callq 0x7170
movq %r12, %rdi
callq 0x7980
movq %r12, %rdi
leaq 0x278d(%rip), %rsi      # 0x1254d
callq 0x77f0
movq %r14, %rdi
movq %r12, %rsi
callq 0x77b0
movl %eax, %ebx
movq %r12, %rdi
callq 0x7980
testb %bl, %bl
je 0xfe75
movq %r12, %rdi
leaq 0x2766(%rip), %rsi      # 0x12552
callq 0x77f0
movq %r15, %rdi
movq %r12, %rsi
callq 0x7170
movq %r12, %rdi
callq 0x7980
movq %r14, %rdi
callq 0x7280
addl $-0x4, %eax
movq %r12, %rdi
movq %r14, %rsi
movl %eax, %edx
callq 0x7340
movq %r14, %rdi
movq %r12, %rsi
callq 0x7550
jmp 0xfdae
movq %r12, %rdi
leaq 0x271c(%rip), %rsi      # 0x1254f
callq 0x77f0
movq %r15, %rdi
movq %r12, %rsi
callq 0x7170
movq %r12, %rdi
callq 0x7980
movq %r14, %rdi
callq 0x7280
decl %eax
movq %r12, %rdi
movq %r14, %rsi
movl %eax, %edx
callq 0x7340
movq %r14, %rdi
movq %r12, %rsi
callq 0x7550
movq %r12, %rdi
callq 0x7980
movq %r12, %rdi
movq %rbp, %rsi
callq 0x77f0
movq %r14, %rdi
movq %r12, %rsi
callq 0x77b0
movl %eax, %ebx
movq %r12, %rdi
callq 0x7980
testb %bl, %bl
jne 0xfe29
movq %r15, %rdi
movq %r14, %rsi
callq 0x7170
movq %rax, %rbx
movq %r12, %rdi
leaq 0x2690(%rip), %rsi      # 0x12541
callq 0x77f0
movq %rbx, %rdi
movq %r12, %rsi
callq 0x7170
movq %r12, %rdi
callq 0x7980
movq %r14, %rdi
callq 0x7980
cmpw $0x0, 0x90(%rsp)
jne 0xfd2e
movw $0x5, 0x180(%rsp)
leaq 0x190(%rsp), %rdi
movl $0x3, %esi
movq 0x20(%rsp), %rdx
movl $0x1, %ecx
callq 0x7880
leaq 0x190(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0x75b0
leaq 0x190(%rsp), %rdi
callq 0x7690
leaq 0x190(%rsp), %rdi
callq 0x7610
leaq 0x28(%rsp), %rdi
callq 0x7980
leaq 0x88(%rsp), %rdi
callq 0x7520
leaq 0x40(%rsp), %rdi
callq 0x10888
leaq 0x58(%rsp), %rdi
callq 0x108b6
addq $0x298, %rsp            # imm = 0x298
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0xffb4
movq %rax, %rbx
jmp 0xfffa
movq %rax, %rbx
jmp 0x10007
movq %rax, %rbx
jmp 0x10011
movq %rax, %rbx
leaq 0x190(%rsp), %rdi
callq 0x7610
jmp 0xfff0
jmp 0xffcf
jmp 0xffe0
jmp 0xffe0
jmp 0xffe0
jmp 0xffcf
movq %rax, %rbx
leaq 0x70(%rsp), %rdi
callq 0x7980
jmp 0xffd2
movq %rax, %rbx
jmp 0xfff0
jmp 0xffcf
jmp 0xffe0
jmp 0xffcf
jmp 0xffe0
jmp 0xffcf
jmp 0xffcf
jmp 0xffcf
jmp 0xffe0
jmp 0xffcf
jmp 0xffe0
jmp 0xffe0
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x7980
jmp 0xffe3
jmp 0xffe0
movq %rax, %rbx
leaq 0x190(%rsp), %rdi
callq 0x7980
leaq 0x28(%rsp), %rdi
callq 0x7980
leaq 0x88(%rsp), %rdi
callq 0x7520
leaq 0x40(%rsp), %rdi
callq 0x10888
leaq 0x58(%rsp), %rdi
callq 0x108b6
movq %rbx, %rdi
callq 0x7290
nop