diff --git a/package/package_debian.sh b/package/package_debian.sh index 7dd9954e..7c7af4ed 100644 --- a/package/package_debian.sh +++ b/package/package_debian.sh @@ -25,8 +25,8 @@ WHOAMI="David Bannon " MANUALS_DIR="BUILD/usr/share/doc/$PRODUCT/" MANUALS=`cat note-files` -# BUILDOPTS=" -B --quiet --quiet" -BUILDOPTS=" -B --quiet" +BUILDOPTS=" -B --quiet --quiet" +# BUILDOPTS=" -B --quiet" BUILDDATE=`date -R` LAZ_FULL_DIR="$1" LAZ_DIR=`basename "$LAZ_FULL_DIR"` @@ -160,22 +160,24 @@ function DoZipping { rm *.zip rm -Rf "$PRODUCT"_"$VERSION" - mkdir "$PRODUCT"_"$VERSION" - cp ../tomboy-ng/tomboy-ng64.exe "$PRODUCT"_"$VERSION/." - cp ../../DLL_64bit/libhunspell.dll "$PRODUCT"_"$VERSION/." - cp ../../DLL_64bit/libhunspell.license "$PRODUCT"_"$VERSION/." - cp ../COPYING "$PRODUCT"_"$VERSION/." - cp AfterInstall.txt "$PRODUCT"_"$VERSION/." - sed "s/MyAppVersion \"0.21\"/MyAppVersion \"$VERSION\"/" tomboy-ng.iss > "$PRODUCT"_"$VERSION/tomboy-ng.iss" - for i in $MANUALS; do - cp ../doc/$i "$PRODUCT"_"$VERSION/." - done; - MANWIDTH=70 man -l ../doc/tomboy-ng.1 > "$PRODUCT"_"$VERSION/readme.txt" - unix2dos "$PRODUCT"_"$VERSION/readme.txt" - zip "$PRODUCT"_win64_"$VERSION.zip" "$PRODUCT"_"$VERSION"/* - cp ../tomboy-ng/tomboy-ng32.exe . - zip "$PRODUCT"_win32_"$VERSION.zip" tomboy-ng32.exe + # we don't make individual win zip files anymore. + # mkdir "$PRODUCT"_"$VERSION" + # cp ../tomboy-ng/tomboy-ng64.exe "$PRODUCT"_"$VERSION/." + # cp ../../DLL_64bit/libhunspell.dll "$PRODUCT"_"$VERSION/." + # cp ../../DLL_64bit/libhunspell.license "$PRODUCT"_"$VERSION/." + # cp ../COPYING "$PRODUCT"_"$VERSION/." + # cp AfterInstall.txt "$PRODUCT"_"$VERSION/." + # sed "s/MyAppVersion \"REPLACEME\"/MyAppVersion \"$VERSION\"/" tomboy-ng.iss > "$PRODUCT"_"$VERSION/tomboy-ng.iss" + # for i in $MANUALS; do + # cp ../doc/$i "$PRODUCT"_"$VERSION/." + # done; + # MANWIDTH=70 man -l ../doc/tomboy-ng.1 > "$PRODUCT"_"$VERSION/readme.txt" + # unix2dos "$PRODUCT"_"$VERSION/readme.txt" + # zip "$PRODUCT"_win64_"$VERSION.zip" "$PRODUCT"_"$VERSION"/* + # cp ../tomboy-ng/tomboy-ng32.exe . + # zip "$PRODUCT"_win32_"$VERSION.zip" tomboy-ng32.exe + # Make a zip containing everything we need to make a 32/64bit Inno Setup installer for Windows rm -Rf WinPre_"$VERSION" @@ -185,7 +187,7 @@ function DoZipping { cp ../../DLL_64bit/libhunspell.license WinPre_"$VERSION/." cp ../COPYING WinPre_"$VERSION/." cp AfterInstall.txt WinPre_"$VERSION/." - sed "s/MyAppVersion \"0.21\"/MyAppVersion \"$VERSION\"/" tomboy-ng.iss > WinPre_"$VERSION/tomboy-ng.iss" + sed "s/MyAppVersion \"REPLACEME\"/MyAppVersion \"$VERSION\"/" tomboy-ng.iss > WinPre_"$VERSION/tomboy-ng.iss" for i in $MANUALS; do cp ../doc/$i WinPre_"$VERSION/." done; @@ -193,7 +195,7 @@ function DoZipping { cp ../tomboy-ng/tomboy-ng32.exe WinPre_"$VERSION"/. unix2dos WinPre_"$VERSION/readme.txt" ls -la WinPre_"$VERSION" - zip WinPre_"$VERSION.zip" WinPre_"$VERSION"/* + # zip WinPre_"$VERSION.zip" WinPre_"$VERSION"/* echo "--------------- FINISHED ZIPPING ----------------" ls -l *.gz *.zip diff --git a/package/version b/package/version index 0ed82a4b..e3462940 100644 --- a/package/version +++ b/package/version @@ -1 +1 @@ -0.21b +0.22 diff --git a/tomboy-ng/Tomboy_NG.lpi b/tomboy-ng/Tomboy_NG.lpi index 5ecabd01..c827e89c 100644 --- a/tomboy-ng/Tomboy_NG.lpi +++ b/tomboy-ng/Tomboy_NG.lpi @@ -61,12 +61,6 @@ - - - - - - @@ -574,7 +568,7 @@ - + @@ -689,6 +683,11 @@ + + + + + diff --git a/tomboy-ng/mainunit.pas b/tomboy-ng/mainunit.pas index 6f830c14..fef3c935 100644 --- a/tomboy-ng/mainunit.pas +++ b/tomboy-ng/mainunit.pas @@ -143,7 +143,7 @@ TMainForm = class(TForm) function CommandLineError() : boolean; // responds to any main or mainPopup menu clicks except recent note ones. procedure FileMenuClicked(Sender: TObject); - function FindHelpFiles(): integer; + procedure FindHelpFiles(); procedure ShowAbout(); procedure TestDarkThemeInUse(); @@ -338,6 +338,8 @@ procedure TMainForm.FormShow(Sender: TObject); if Sett.CheckShowSearchAtStart.Checked then SearchForm.Show; end; + if UseTrayMenu then + TrayIcon.Show; end; resourcestring @@ -372,8 +374,6 @@ procedure TMainForm.UpdateNotesFound(Numb : integer); if (ImageConfigTick.Visible and ImageNotesDirTick.Visible) then begin ButtonDismiss.Enabled := AllowDismiss; - if UseTrayMenu then - TrayIcon.Show; end; end; @@ -517,15 +517,17 @@ procedure TMainForm.ButtonConfigClick(Sender: TObject); { ------------- M E N U M E T H O D S ----------------} -function TMainForm.FindHelpFiles() : integer; +procedure TMainForm.FindHelpFiles(); // Todo : this uses about 300K, 3% of extra memory, better to code up a simpler model ? var NoteTitle : string; begin + if HelpNotes = Nil then begin HelpNotes := TNoteLister.Create; // freed in OnClose event. HelpNotes.DebugMode := Application.HasOption('debug-index'); HelpNotes.WorkingDir:=HelpNotesPath; - Result := HelpNotes.GetNotes('', true); + HelpNotes.GetNotes('', true); + end; HelpNotes.StartSearch(); while HelpNotes.NextNoteTitle(NoteTitle) do AddMenuItem(NoteTitle, mtHelp, @FileMenuClicked, mkHelpMenu); diff --git a/tomboy-ng/note_lister.pas b/tomboy-ng/note_lister.pas index 96ea6d50..c114409c 100644 --- a/tomboy-ng/note_lister.pas +++ b/tomboy-ng/note_lister.pas @@ -503,13 +503,13 @@ procedure TNoteLister.CleanupList(const Lst : TNoteList); for Index := 0 to Lst.count -1 do begin; while UTF8length(Lst.Items[Index]^.CreateDate) < 20 do Lst.Items[Index]^.CreateDate := Lst.Items[Index]^.CreateDate + ' '; - Lst.Items[Index]^.CreateDate := copy(Lst.Items[Index]^.CreateDate, 1, 19); - Lst.Items[Index]^.CreateDate[11] := ' '; - while UTF8length(Lst.Items[Index]^.LastChange) < 20 do - Lst.Items[Index]^.LastChange := Lst.Items[Index]^.LastChange + ' '; - Lst.Items[Index]^.LastChange := copy(Lst.Items[Index]^.LastChange, 1, 19); - Lst.Items[Index]^.LastChange[11] := ' '; - end; + Lst.Items[Index]^.CreateDate := copy(Lst.Items[Index]^.CreateDate, 1, 19); + Lst.Items[Index]^.CreateDate[11] := ' '; + while UTF8length(Lst.Items[Index]^.LastChange) < 20 do + Lst.Items[Index]^.LastChange := Lst.Items[Index]^.LastChange + ' '; + Lst.Items[Index]^.LastChange := copy(Lst.Items[Index]^.LastChange, 1, 19); + Lst.Items[Index]^.LastChange[11] := ' '; + end; end; procedure TNoteLister.GetNoteDetails(const Dir, FileName: ANSIString; const SearchTerm: ANSIString; DontTestName : boolean = false); @@ -533,7 +533,7 @@ procedure TNoteLister.GetNoteDetails(const Dir, FileName: ANSIString; const Sear new(NoteP); NoteP^.IsTemplate := False; try - try + try NoteP^.ID:=FileName; ReadXMLFile(Doc, Dir + FileName); Node := Doc.DocumentElement.FindNode('title'); @@ -544,7 +544,6 @@ procedure TNoteLister.GetNoteDetails(const Dir, FileName: ANSIString; const Sear NoteP^.OpenNote := nil; Node := Doc.DocumentElement.FindNode('create-date'); NoteP^.CreateDate := Node.FirstChild.NodeValue; - Node := Doc.DocumentElement.FindNode('tags'); if Assigned(Node) then begin for J := 0 to Node.ChildNodes.Count-1 do @@ -553,19 +552,19 @@ procedure TNoteLister.GetNoteDetails(const Dir, FileName: ANSIString; const Sear for J := 0 to Node.ChildNodes.Count-1 do if UTF8pos('system:notebook', Node.ChildNodes.Item[J].TextContent) > 0 then NoteBookList.Add(Filename, UTF8Copy(Node.ChildNodes.Item[J].TextContent, 17, 1000), NoteP^.IsTemplate); - // Node.ChildNodes.Item[J].TextContent) may be something like - - // * system:notebook:DavosNotebook - this note belongs to DavosNotebook - // * system:template - this note is a template, if does not also have a - // Notebook tag its the StartHere note, otherwise its the Template for - // for the mentioned Notebook. + // Node.ChildNodes.Item[J].TextContent) may be something like - + // * system:notebook:DavosNotebook - this note belongs to DavosNotebook + // * system:template - this note is a template, if does not also have a + // Notebook tag its the StartHere note, otherwise its the Template for + // for the mentioned Notebook. end; except on E: EXMLReadError do begin - DebugLn(E.Message); - XMLError := True; - dispose(NoteP); - ErrorNotes.Append(FileName + ', ' + E.Message); - exit(); - end; + DebugLn('XML ERROR' + E.Message); + XMLError := True; + dispose(NoteP); + ErrorNotes.Append(FileName + ', ' + E.Message); + exit(); + end; on EAccessViolation do DebugLn('Access Violation ' + FileName); end; if NoteP^.IsTemplate then begin // Don't show templates in normal note list @@ -815,8 +814,8 @@ procedure TNoteLister.ThisNoteIsOpen(const ID : ANSIString; const TheForm: TForm if NoteList = NIl then exit; if NoteList.Count < 1 then begin - DebugLn('Called ThisNoteIsOpen() with empty but not NIL list. Count is ' - + inttostr(NoteList.Count) + ' ' + ID); + //DebugLn('Called ThisNoteIsOpen() with empty but not NIL list. Count is ' + // + inttostr(NoteList.Count) + ' ' + ID); // Occasionally I think we see a non reproducable error here. // I believe is legal to start the for loop below with an empty list but .... // When we are creating the very first note in a dir, this haappens. Count should be exactly zero. diff --git a/tomboy-ng/searchunit.lfm b/tomboy-ng/searchunit.lfm index cb796228..c9f1e93d 100644 --- a/tomboy-ng/searchunit.lfm +++ b/tomboy-ng/searchunit.lfm @@ -1,7 +1,7 @@ object SearchForm: TSearchForm - Left = 157 + Left = 483 Height = 401 - Top = 190 + Top = 291 Width = 824 Caption = 'SearchForm' ClientHeight = 401 @@ -52,7 +52,7 @@ object SearchForm: TSearchForm end object Panel1: TPanel AnchorSideLeft.Control = Owner - AnchorSideTop.Control = Edit1 + AnchorSideTop.Control = SpeedButton1 AnchorSideTop.Side = asrBottom AnchorSideRight.Control = Owner AnchorSideRight.Side = asrBottom