groffstudio

Check-in [d0b6777baf]
Login
Overview
Comment:Cleaned up redundant code.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: d0b6777baf89e70633e5da150681ea251a1c266f96d3334da43844970cd72180
User & Date: Cthulhux on 2024-04-30 09:53:47
Other Links: manifest | tags
Context
2024-04-30
12:10
[Feature] There is an option to keep both the .ps and the .pdf file now. [Feature] Non-Windows users can choose to use Ghostscript (if installed) or pdfroff. check-in: 80a9157eaf user: Cthulhux tags: trunk
09:53
Cleaned up redundant code. check-in: d0b6777baf user: Cthulhux tags: trunk
09:51
Simplified build status output on Windows check-in: 300ab98f2c user: Cthulhux tags: trunk
Changes

Modified src/groffstudio.lpi from [a064dbe3a0] to [8051bc1bdc].

19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
        <Resource_0 FileName="..\LICENSE" Type="RCDATA" ResourceName="LICENSE"/>
      </Resources>
    </General>
    <VersionInfo>
      <UseVersionInfo Value="True"/>
      <AutoIncrementBuild Value="True"/>
      <MinorVersionNr Value="14"/>
      <BuildNr Value="3"/>
      <StringTable ProductName="groffstudio"/>
    </VersionInfo>
    <BuildModes>
      <Item Name="Default" Default="True"/>
    </BuildModes>
    <PublishOptions>
      <Version Value="2"/>







|







19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
        <Resource_0 FileName="..\LICENSE" Type="RCDATA" ResourceName="LICENSE"/>
      </Resources>
    </General>
    <VersionInfo>
      <UseVersionInfo Value="True"/>
      <AutoIncrementBuild Value="True"/>
      <MinorVersionNr Value="14"/>
      <BuildNr Value="4"/>
      <StringTable ProductName="groffstudio"/>
    </VersionInfo>
    <BuildModes>
      <Item Name="Default" Default="True"/>
    </BuildModes>
    <PublishOptions>
      <Version Value="2"/>

Modified src/unit1.pas from [a9449c1e7e] to [6d1c34ba48].

132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151

152


153
154
155

156
157
158
159
160
161
162

implementation

{$R *.lfm}

procedure TDetectGroffThread.UpdateUI;
begin
  // groff:
  MainForm.edtGroffInstalledVersion.Text := GroffOutputVersion;
  if pos('GNU', GroffOutputVersion) = 0 then
  begin
    ShowMessage('groffstudio thinks that your installed version of troff is not GNU troff.'
      + LineEnding + 'If this is correct, you are advised to fix this before continuing.'
      + LineEnding +
      'If it is an error, please tell me so I can improve this detection.');
    hasGroff := False;
    MainForm.edtGroffInstalledVersion.Text := 'n/a';
    MainForm.lblTroffCommandNotFound.Visible := True;
  end
  else

    hasGroff := True;



  // ps2pdf (Windows-only):
  {$IFDEF WINDOWS}

  if pos('ps2pdf', ps2pdfOutput) = 0 then
  begin
    ShowMessage('On Windows, for creating PDF files, you need Ghostscript installed.'
    + LineEnding + 'Sadly, groffstudio could not find ps2pdf.exe in your %PATH%, so '
    + 'writing PDF files will not be supported.');
    hasGhostscript := False;
    MainForm.rdPdf.Enabled := False;







|
<











>

>
>

<

>







132
133
134
135
136
137
138
139

140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155

156
157
158
159
160
161
162
163
164

implementation

{$R *.lfm}

procedure TDetectGroffThread.UpdateUI;
begin
  // Try to find groff:

  if pos('GNU', GroffOutputVersion) = 0 then
  begin
    ShowMessage('groffstudio thinks that your installed version of troff is not GNU troff.'
      + LineEnding + 'If this is correct, you are advised to fix this before continuing.'
      + LineEnding +
      'If it is an error, please tell me so I can improve this detection.');
    hasGroff := False;
    MainForm.edtGroffInstalledVersion.Text := 'n/a';
    MainForm.lblTroffCommandNotFound.Visible := True;
  end
  else
  begin
    hasGroff := True;
    MainForm.edtGroffInstalledVersion.Text := GroffOutputVersion;
  end;


  {$IFDEF WINDOWS}
  // Try to find ps2pdf (Windows-only):
  if pos('ps2pdf', ps2pdfOutput) = 0 then
  begin
    ShowMessage('On Windows, for creating PDF files, you need Ghostscript installed.'
    + LineEnding + 'Sadly, groffstudio could not find ps2pdf.exe in your %PATH%, so '
    + 'writing PDF files will not be supported.');
    hasGhostscript := False;
    MainForm.rdPdf.Enabled := False;