diff --git a/examples/anchordocking/docking1.lpi b/examples/anchordocking/docking1.lpi index 03f6ea7add..be32a06d54 100644 --- a/examples/anchordocking/docking1.lpi +++ b/examples/anchordocking/docking1.lpi @@ -1,24 +1,23 @@ - + - + - - + @@ -58,7 +57,6 @@ - diff --git a/install/lazarus.desktop b/install/lazarus.desktop index a4fc83686f..636d49ee84 100644 --- a/install/lazarus.desktop +++ b/install/lazarus.desktop @@ -1,7 +1,7 @@ [Desktop Entry] Name=Lazarus Comment=Lazarus IDE -Exec=/usr/bin/startlazarus %f +Exec=startlazarus %f Terminal=false Type=Application Icon=lazarus.png diff --git a/lcl/ldockctrl.pas b/lcl/ldockctrl.pas index 39cd32da6c..15c160c1e1 100644 --- a/lcl/ldockctrl.pas +++ b/lcl/ldockctrl.pas @@ -28,8 +28,8 @@ - restoring layout: pages - restoring layout: move form after inserting a control - restoring layout: spiral splitter - - save TLazDockConfigNode to stream - - load TLazDockConfigNode from stream + - save TLazDockConfigNode to stream (atm only xml implemented) + - load TLazDockConfigNode from stream (atm only xml implemented) } unit LDockCtrl; @@ -724,6 +724,8 @@ end; function TCustomLazControlDocker.DockAsPage(Layout: TLazDockConfigNode ): boolean; +// dock as page like in Layout +// Requirements: Parent in Layout is a ldcntPage and a parent control exists. var SelfNode: TLazDockConfigNode; PageNode: TLazDockConfigNode; @@ -739,6 +741,7 @@ var PageIndex: LongInt; NeighbourList: TFPList; AnchorControls: TAnchorControls; + TopFormBounds: TRect; begin Result:=false; DebugLn(['TCustomLazControlDocker.DockAsPage DockerName="',DockerName,'"']); @@ -757,7 +760,7 @@ begin exit; end; if PageNode.ChildCount<>1 then begin - DebugLn(['TCustomLazControlDocker.DockAsPage SelfNode.Parent.TheType<>ldcntPage DockerName="',DockerName,'"']); + DebugLn(['TCustomLazControlDocker.DockAsPage PageNode.ChildCount<>1 DockerName="',DockerName,'"']); exit; end; @@ -769,15 +772,18 @@ begin NeighbourNode:=PagesNode.Childs[PageNodeIndex+1].Childs[0]; NeighbourControl:=Manager.FindControlByDockerName(NeighbourNode.Name); if NeighbourControl=nil then begin - DebugLn(['TCustomLazControlDocker.CreateFormAndDockWithSplitter NeighbourControl not found "',NeighbourNode.Name,'"']); + DebugLn(['TCustomLazControlDocker.DockAsPage NeighbourControl not found "',NeighbourNode.Name,'"']); exit; end; if NeighbourControl.Parent=nil then begin - // NeighbourControl is a single top level control + // NeighbourControl is a top level control (no parents, no neighbours) // => create a TLazDockForm with a TLazDockPages and two TLazDockPage TopForm:=TLazDockForm.Create(nil); - // TODO: resize TopForm + TopFormBounds:=PagesNode.Bounds; + // TODO: shrink TopFormBounds + TopForm.BoundsRect:=TopFormBounds; + Pages:=TLazDockPages.Create(nil); Pages.DisableAlign; try @@ -817,7 +823,7 @@ begin Page:=Pages.Page[PageIndex]; Control.Parent:=Page; Control.AnchorClient(0); - // TODO resize parents + // TODO enlarge parents end else begin // NeighbourControl is a child control, but the parent is not yet a page // => collect all neighbour controls for a page @@ -1613,7 +1619,7 @@ var Result:=Manager.FindControlByDockerName(ADockerName); end; - function DockWithSpiralSpltter: boolean; + function DockWithSpiralSplitter: boolean; begin // TODO Result:=false; @@ -1636,7 +1642,7 @@ var and CreateFormAndDockWithSplitter(Layout,a) then exit(true); inc(SplitterCount); - if (SplitterCount=4) and DockWithSpiralSpltter then + if (SplitterCount=4) and DockWithSpiralSplitter then exit(true); end; end; diff --git a/tools/install/create_lazarus_export_tgz.sh b/tools/install/create_lazarus_export_tgz.sh index 334ceb8f2b..4b6e16e1f5 100755 --- a/tools/install/create_lazarus_export_tgz.sh +++ b/tools/install/create_lazarus_export_tgz.sh @@ -30,6 +30,10 @@ else svn export $SourceDir /tmp/lazarus fi +# add ide/revision.inc +Revision=$(cat /tmp/lazarus/.svn/entries | grep committed-rev= | head -n 1 | cut -d\" -f2) +echo "const RevisionStr = '$Revision';" > /tmp/lazarus/ide/revision.inc + cd /tmp echo "packing ..." tar cvzf lazarus.tgz lazarus diff --git a/tools/install/create_lazarus_rpm.sh b/tools/install/create_lazarus_rpm.sh index 1efdfb88a2..e2eff9ca72 100755 --- a/tools/install/create_lazarus_rpm.sh +++ b/tools/install/create_lazarus_rpm.sh @@ -15,8 +15,9 @@ if [ "x$FPCRPM" = "x" ]; then echo ERROR: fpc rpm not installed exit fi -FPCRPMVersion=`echo $FPCRPM | sed -e 's/fpc-//g'` +FPCRPMVersion=$(echo $FPCRPM | sed -e 's/fpc-//g') echo "installed fpc version: $FPCRPMVersion" +FPCSRCRPMVersion=$(echo $FPCRPMVersion | cut -d- -f1) Date=$Year$Month$Day LazVersion=$(./get_lazarus_version.sh) @@ -40,6 +41,7 @@ cat rpm/lazarus.spec.template | \ -e "s/LAZSOURCE/$Src/g" \ -e "s/FPCBUILDVERSION/2.0.0/g" \ -e "s/FPCVERSION/$FPCRPMVersion/g" \ + -e "s/FPCSRCVERSION/$FPCSRCRPMVersion/g" \ > $SpecFile # build rpm diff --git a/tools/install/rpm/lazarus.spec.template b/tools/install/rpm/lazarus.spec.template index 5b0916bea4..55da06ccd2 100644 --- a/tools/install/rpm/lazarus.spec.template +++ b/tools/install/rpm/lazarus.spec.template @@ -11,7 +11,7 @@ Packager: Mattias Gaertner BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) #BuildRequires: -Requires: fpc-src = FPCVERSION, fpc = FPCVERSION, gdk-pixbuf, gtk+, glibc, gdb +Requires: fpc-src = FPCSRCVERSION, fpc = FPCVERSION, gdk-pixbuf, gtk+, glibc, gdb # NOTE: without the symlink trick for gtk1, it requires the devel packages. Requires(post): desktop-file-utils