View Issue Details

IDProjectCategoryView StatusLast Update
0006230ScribusGraphics / Image Framespublic2024-01-02 19:22
ReporterTomZ Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status acknowledgedResolutionopen 
PlatformIndependentOSIndependentOS VersionIndependent
Target Version1.6 milestone 
Summary0006230: Feature request: alignment of images within an image frame
DescriptionWhen an image is smaller than it's frame, it would be fine to align the image automatically inside the frame: for example, align the image horizontal and / or vertical inside the frame, align it to the right border of the frame etc.

At the moment, this functionality can achieved by a script: http://wiki.scribus.net/index.php/Align_an_Image_in_its_Frame
TagsHOST-Oman
PatchYes

Relationships

related to 0006228 closed Feature requests for image frames 
related to 0005662 acknowledged Positioning of image within image frames. 

Activities

jon.grossart

2014-02-09 03:57

reporter   ~0031288

This is a really old request, that seems like a very basic feature for a DTP program to have.

Use Case: brochures
If I've setup guides to cover the printable space, it would be nice to just expand the text frame to the sides and set an "image centered" property so that I can guarantee the spacing without have to resort to the calculations or using a script.

ale

2014-09-19 08:28

manager   ~0033756

i'm for adding this feature to the align and distribute dialog.

Dawoodalbadi

2015-10-26 09:46

reporter   ~0036943

hello guys
I am working in this feature or something similar but I got lost in some points if any one can help me

what I did exactly that I add new combobox in PropertiesPalette_Image that will have 9 option (top-left , top-middle , botton-right ... etc) according to the choice the image will move in the frame to the new x and new y coordinate , the problem is calculating the new x,y. for that I will need width and hight for the image and the frame. so I stop their for a moment. if any one can help how to get the width and hight for the both image and frame

Dawoodalbadi

2015-10-27 21:54

reporter   ~0036998

hello again
i finish this feature
my work is as following
i add 2 combo box for alignment
first one is vertical which has three options (top ,center,bottom)
the second is horizontal which has also 3 options (left , center ,right )
if the image is smaller than the frame so you can move it by these options
the new options is in property >>> image >>> align image

thank you

Dawoodalbadi

2015-10-27 21:55

reporter  

alignImage.diff (10,087 bytes)   
Index: scribus/ui/propertiespalette_image.cpp
===================================================================
--- scribus/ui/propertiespalette_image.cpp	(revision 20473)
+++ scribus/ui/propertiespalette_image.cpp	(working copy)
@@ -110,6 +110,9 @@
 	connect(renderIntent       , SIGNAL(activated(int))      , this, SLOT(handleIntent()));
 	connect(compressionMethod  , SIGNAL(activated(int))      , this, SLOT(handleCompressionMethod()));
 	connect(compressionQuality , SIGNAL(activated(int))      , this, SLOT(handleCompressionQuality()));
+    connect(alignvertical , SIGNAL(currentIndexChanged(int)) , this, SLOT(alignImageVertical(int)));
+    connect(alignhorozintal , SIGNAL(currentIndexChanged(int)), this, SLOT(alignImageHorozintal(int)));
+
 }
 
 void PropertiesPalette_Image::changeEvent(QEvent *e)
@@ -890,4 +893,59 @@
 	}
 }
 
+void PropertiesPalette_Image::alignImageVertical(int in){
+    double imagex,imagey,heightf ,heightim;
+    //imagex = m_item->pixm.imgInfo.xres();
 
+
+    if (!m_ScMW || m_ScMW->scriptIsRunning())
+        return;
+    if ((m_haveDoc) && (m_haveItem) && (m_item->asImageFrame()))
+    {
+
+        // widthim = m_item->pixm.width();
+        heightim = m_item->pixm.height();
+        // widthf = m_item->width();
+        heightf = m_item->height();
+
+        if (in == 0);
+        else if (in == 1)imagey = 0;
+        else if (in == 2)imagey = (heightf- heightim)/2.0;
+        else imagey = heightf - heightim ;
+
+        imagex = m_item->imageXOffset();
+        m_doc->itemSelection_SetImageOffset(imagex, imagey);
+        m_item->update();
+
+    }
+    else ;//add error massage
+
+}
+void PropertiesPalette_Image::alignImageHorozintal(int in){
+    double imagex,imagey,widthf,widthim;
+    //imagex = m_item->pixm.imgInfo.xres();
+
+
+    if (!m_ScMW || m_ScMW->scriptIsRunning())
+        return;
+    if ((m_haveDoc) && (m_haveItem) && (m_item->asImageFrame()))
+    {
+
+        widthim = m_item->pixm.width();
+        //heightim = m_item->pixm.height();
+        widthf = m_item->width();
+        //heightf = m_item->height();
+
+        if (in == 0);
+        else if (in == 1)imagex = 0;
+        else if (in == 2)imagex = (widthf - widthim)/2.0;
+        else imagex = widthf - widthim ;
+
+        imagey = m_item->imageYOffset();
+        m_doc->itemSelection_SetImageOffset(imagex, imagey);
+        m_item->update();
+
+    }
+    else ; //add error message
+}
+
Index: scribus/ui/propertiespalette_image.h
===================================================================
--- scribus/ui/propertiespalette_image.h	(revision 20473)
+++ scribus/ui/propertiespalette_image.h	(working copy)
@@ -102,6 +102,8 @@
 
 	void handleImageEffects();
 	void handleExtImgProperties();
+    void alignImageVertical(int);
+    void alignImageHorozintal(int);
 
 signals:
 	void UpdtGui(int);
Index: scribus/ui/propertiespalette_imagebase.ui
===================================================================
--- scribus/ui/propertiespalette_imagebase.ui	(revision 20473)
+++ scribus/ui/propertiespalette_imagebase.ui	(working copy)
@@ -6,8 +6,8 @@
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>286</width>
-    <height>617</height>
+    <width>297</width>
+    <height>682</height>
    </rect>
   </property>
   <property name="windowTitle">
@@ -17,9 +17,18 @@
    <property name="spacing">
     <number>2</number>
    </property>
-   <property name="margin">
+   <property name="leftMargin">
     <number>2</number>
    </property>
+   <property name="topMargin">
+    <number>2</number>
+   </property>
+   <property name="rightMargin">
+    <number>2</number>
+   </property>
+   <property name="bottomMargin">
+    <number>2</number>
+   </property>
    <item>
     <layout class="QGridLayout" name="gridLayout">
      <item row="2" column="0">
@@ -63,13 +72,6 @@
        </property>
       </widget>
      </item>
-     <item row="3" column="0">
-      <widget class="QLabel" name="yposImgLabel">
-       <property name="text">
-        <string>Y-Pos:</string>
-       </property>
-      </widget>
-     </item>
      <item row="3" column="1">
       <widget class="ScrSpinBox" name="imageYOffsetSpinBox">
        <property name="sizePolicy">
@@ -80,6 +82,13 @@
        </property>
       </widget>
      </item>
+     <item row="3" column="0">
+      <widget class="QLabel" name="yposImgLabel">
+       <property name="text">
+        <string>Y-Pos:</string>
+       </property>
+      </widget>
+     </item>
      <item row="1" column="1">
       <widget class="ScrSpinBox" name="imagePageNumber">
        <property name="specialValueText">
@@ -151,10 +160,10 @@
         </property>
        </widget>
       </item>
-      <item row="4" column="0">
-       <widget class="QLabel" name="imgDPIXLabel">
+      <item row="5" column="0">
+       <widget class="QLabel" name="imgDPIYLabel">
         <property name="text">
-         <string>Actual X-DPI:</string>
+         <string>Actual Y-DPI:</string>
         </property>
        </widget>
       </item>
@@ -161,10 +170,10 @@
       <item row="4" column="1">
        <widget class="ScrSpinBox" name="imgDpiX"/>
       </item>
-      <item row="5" column="0">
-       <widget class="QLabel" name="imgDPIYLabel">
+      <item row="4" column="0">
+       <widget class="QLabel" name="imgDPIXLabel">
         <property name="text">
-         <string>Actual Y-DPI:</string>
+         <string>Actual X-DPI:</string>
         </property>
        </widget>
       </item>
@@ -200,14 +209,88 @@
         </property>
        </widget>
       </item>
-      <item row="7" column="1">
-       <widget class="QCheckBox" name="cbProportional">
+      <item row="10" column="1">
+       <widget class="QLabel" name="label_3">
         <property name="text">
-         <string>Proportional</string>
+         <string>Horozental</string>
         </property>
        </widget>
       </item>
-      <item row="6" column="0">
+      <item row="11" column="0">
+       <widget class="QComboBox" name="alignvertical">
+        <item>
+         <property name="text">
+          <string>Default</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Top</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Center</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Bottom</string>
+         </property>
+        </item>
+       </widget>
+      </item>
+      <item row="11" column="1">
+       <widget class="QComboBox" name="alignhorozintal">
+        <item>
+         <property name="text">
+          <string>Default</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Left</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Center</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Right</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string/>
+         </property>
+        </item>
+       </widget>
+      </item>
+      <item row="9" column="0">
+       <widget class="QLabel" name="label">
+        <property name="font">
+         <font>
+          <pointsize>11</pointsize>
+          <weight>75</weight>
+          <bold>true</bold>
+         </font>
+        </property>
+        <property name="text">
+         <string>Align Image</string>
+        </property>
+       </widget>
+      </item>
+      <item row="10" column="0">
+       <widget class="QLabel" name="label_2">
+        <property name="text">
+         <string>Vertical </string>
+        </property>
+       </widget>
+      </item>
+      <item row="7" column="0">
        <widget class="QRadioButton" name="frameScale">
         <property name="text">
          <string>To Frame Size</string>
@@ -214,6 +297,13 @@
         </property>
        </widget>
       </item>
+      <item row="8" column="0">
+       <widget class="QCheckBox" name="cbProportional">
+        <property name="text">
+         <string>Proportional</string>
+        </property>
+       </widget>
+      </item>
      </layout>
     </widget>
    </item>
@@ -223,13 +313,6 @@
       <string>Color Management</string>
      </property>
      <layout class="QGridLayout" name="gridLayout_4">
-      <item row="0" column="0">
-       <widget class="QLabel" name="inputProfLabel">
-        <property name="text">
-         <string>Input Profile</string>
-        </property>
-       </widget>
-      </item>
       <item row="0" column="1">
        <widget class="QComboBox" name="inputProfiles">
         <property name="sizePolicy">
@@ -250,6 +333,13 @@
       <item row="1" column="1">
        <widget class="QComboBox" name="renderIntent"/>
       </item>
+      <item row="0" column="0">
+       <widget class="QLabel" name="inputProfLabel">
+        <property name="text">
+         <string>Input Profile</string>
+        </property>
+       </widget>
+      </item>
      </layout>
     </widget>
    </item>
@@ -327,6 +417,9 @@
     </layout>
    </item>
    <item>
+    <layout class="QVBoxLayout" name="verticalLayout_2"/>
+   </item>
+   <item>
     <spacer name="verticalSpacer">
      <property name="orientation">
       <enum>Qt::Vertical</enum>
@@ -365,8 +458,6 @@
   <tabstop>imgDpiY</tabstop>
   <tabstop>keepImageWHRatioButton</tabstop>
   <tabstop>keepImageDPIRatioButton</tabstop>
-  <tabstop>frameScale</tabstop>
-  <tabstop>cbProportional</tabstop>
   <tabstop>inputProfiles</tabstop>
   <tabstop>renderIntent</tabstop>
   <tabstop>compressionMethod</tabstop>
alignImage.diff (10,087 bytes)   

cbradney

2015-10-27 22:35

administrator   ~0037001

When I load the scribus splashscreen into an image frame, it doesn't center vertically and doesnt go to the bottom of the frame either. Center horizontal mightbe ok, but right horizontall is again off.

Typo in Horizontal in GUI.

There's issues with the selection of Default. I assume it should return the image to the top left but it doesn't.

Also, I think the controls might need to be nearer to the X/Y position to understand that it just updates those values.

Also, the case where an image has been scaled needs to be handled properly, by using the scaled width.

Thanks for the patch, let's see how the next revision is.

Dawoodalbadi

2015-10-27 22:59

reporter   ~0037004

Thank you mr cbradny
I dont know why the options doesn't work properly with u ... i try it in to 2 different machines and it works fine but i will check it again and about other points i totally agree with u
I will try to fix it soon
Thank you

cbradney

2015-10-27 23:18

administrator   ~0037006

I suspect that it relates to the height/width calculation .. see documentchecker.cpp isPartFilledImageFrame() for some hints.

Dawoodalbadi

2015-10-28 06:42

reporter   ~0037019

Last edited: 2015-10-28 06:50

sorry I was not understanding what you are meaning last night but now I know
I did handle scale properly in updated patch and I change the location of the alignment control as you request and I made some changes in code layout it looks nice now
I hope there will be no problems now
thank you

Dawoodalbadi

2015-10-28 06:45

reporter  

alignImageUpdated.diff (8,950 bytes)   
Index: scribus/ui/propertiespalette_image.cpp
===================================================================
--- scribus/ui/propertiespalette_image.cpp	(revision 20505)
+++ scribus/ui/propertiespalette_image.cpp	(working copy)
@@ -110,6 +110,8 @@
 	connect(renderIntent       , SIGNAL(activated(int))      , this, SLOT(handleIntent()));
 	connect(compressionMethod  , SIGNAL(activated(int))      , this, SLOT(handleCompressionMethod()));
 	connect(compressionQuality , SIGNAL(activated(int))      , this, SLOT(handleCompressionQuality()));
+	connect(alignvertical , SIGNAL(currentIndexChanged(int)) , this, SLOT(alignImageVertical(int)));
+	connect(alignhorozintal , SIGNAL(currentIndexChanged(int)), this, SLOT(alignImageHorozintal(int)));
 }
 
 void PropertiesPalette_Image::changeEvent(QEvent *e)
@@ -890,4 +892,59 @@
 	}
 }
 
+void PropertiesPalette_Image::alignImageVertical(int idx){
+    if (!m_ScMW || m_ScMW->scriptIsRunning())
+	return;
 
+    if ((m_haveDoc) && (m_haveItem) && (m_item->asImageFrame()))
+    {
+	double newY;
+	double imageHeight = m_item->pixm.height() * m_item->imageYScale() * m_item->pixm.imgInfo.lowResScale;
+	double frameHeight= m_item->height();
+
+	switch (idx) 
+	{
+		case 1:
+			newY = 0;
+			break;
+		case 2: 
+			newY = (frameHeight - imageHeight) / 2.0;
+			break;
+		case 3: 
+			newY = frameHeight - imageHeight;
+			break;
+		default:
+			newY = m_item->imageYOffset(); //do nothing
+			break;
+	}
+	m_doc->itemSelection_SetImageOffset(m_item->imageXOffset(), newY / m_item->imageYScale());
+    }
+}
+
+void PropertiesPalette_Image::alignImageHorozintal(int idx) {
+    if (!m_ScMW || m_ScMW->scriptIsRunning())
+	return;
+
+    if ((m_haveDoc) && (m_haveItem) && (m_item->asImageFrame()))
+    {
+	double newX;
+	double imageWidth = m_item->pixm.width() * m_item->imageXScale() * m_item->pixm.imgInfo.lowResScale;
+	double frameWidth = m_item->width();
+	switch (idx)
+	{
+		case 1: 
+			newX = 0;
+			break;
+		case 2:
+			newX = (frameWidth - imageWidth) / 2.0;
+			break;
+		case 3:
+			newX = frameWidth - imageWidth;
+			break;
+		default:
+			newX = m_item->imageXOffset(); // do nothing
+			break;
+	}
+	m_doc->itemSelection_SetImageOffset(newX / m_item->imageXScale(), m_item->imageYOffset());
+    }
+}
Index: scribus/ui/propertiespalette_image.h
===================================================================
--- scribus/ui/propertiespalette_image.h	(revision 20505)
+++ scribus/ui/propertiespalette_image.h	(working copy)
@@ -102,6 +102,8 @@
 
 	void handleImageEffects();
 	void handleExtImgProperties();
+	void alignImageVertical(int);
+	void alignImageHorozintal(int);
 
 signals:
 	void UpdtGui(int);
Index: scribus/ui/propertiespalette_imagebase.ui
===================================================================
--- scribus/ui/propertiespalette_imagebase.ui	(revision 20505)
+++ scribus/ui/propertiespalette_imagebase.ui	(working copy)
@@ -6,8 +6,8 @@
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>286</width>
-    <height>617</height>
+    <width>297</width>
+    <height>690</height>
    </rect>
   </property>
   <property name="windowTitle">
@@ -17,9 +17,18 @@
    <property name="spacing">
     <number>2</number>
    </property>
-   <property name="margin">
+   <property name="leftMargin">
     <number>2</number>
    </property>
+   <property name="topMargin">
+    <number>2</number>
+   </property>
+   <property name="rightMargin">
+    <number>2</number>
+   </property>
+   <property name="bottomMargin">
+    <number>2</number>
+   </property>
    <item>
     <layout class="QGridLayout" name="gridLayout">
      <item row="2" column="0">
@@ -63,13 +72,6 @@
        </property>
       </widget>
      </item>
-     <item row="3" column="0">
-      <widget class="QLabel" name="yposImgLabel">
-       <property name="text">
-        <string>Y-Pos:</string>
-       </property>
-      </widget>
-     </item>
      <item row="3" column="1">
       <widget class="ScrSpinBox" name="imageYOffsetSpinBox">
        <property name="sizePolicy">
@@ -80,6 +82,13 @@
        </property>
       </widget>
      </item>
+     <item row="3" column="0">
+      <widget class="QLabel" name="yposImgLabel">
+       <property name="text">
+        <string>Y-Pos:</string>
+       </property>
+      </widget>
+     </item>
      <item row="1" column="1">
       <widget class="ScrSpinBox" name="imagePageNumber">
        <property name="specialValueText">
@@ -90,6 +99,77 @@
     </layout>
    </item>
    <item>
+    <widget class="QGroupBox" name="alignmentGroupBox">
+     <property name="title">
+      <string>Alignment</string>
+     </property>
+     <layout class="QFormLayout" name="formLayout">
+      <item row="0" column="0">
+       <widget class="QLabel" name="label_2">
+        <property name="text">
+         <string>Horizontal</string>
+        </property>
+       </widget>
+      </item>
+      <item row="2" column="0">
+       <widget class="QLabel" name="label_3">
+        <property name="text">
+         <string>Vertical</string>
+        </property>
+       </widget>
+      </item>
+      <item row="0" column="1">
+       <widget class="QComboBox" name="alignhorozintal">
+        <item>
+         <property name="text">
+          <string>None</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Left</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Center</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Right</string>
+         </property>
+        </item>
+       </widget>
+      </item>
+      <item row="2" column="1">
+       <widget class="QComboBox" name="alignvertical">
+        <item>
+         <property name="text">
+          <string>None</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Top</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Middle</string>
+         </property>
+        </item>
+        <item>
+         <property name="text">
+          <string>Bottom</string>
+         </property>
+        </item>
+       </widget>
+      </item>
+     </layout>
+    </widget>
+   </item>
+   <item>
     <widget class="QGroupBox" name="scalingGroupBox">
      <property name="title">
       <string>Scaling</string>
@@ -200,17 +280,17 @@
         </property>
        </widget>
       </item>
-      <item row="7" column="1">
-       <widget class="QCheckBox" name="cbProportional">
+      <item row="7" column="0">
+       <widget class="QRadioButton" name="frameScale">
         <property name="text">
-         <string>Proportional</string>
+         <string>To Frame Size</string>
         </property>
        </widget>
       </item>
-      <item row="6" column="0">
-       <widget class="QRadioButton" name="frameScale">
+      <item row="8" column="0">
+       <widget class="QCheckBox" name="cbProportional">
         <property name="text">
-         <string>To Frame Size</string>
+         <string>Proportional</string>
         </property>
        </widget>
       </item>
@@ -223,13 +303,6 @@
       <string>Color Management</string>
      </property>
      <layout class="QGridLayout" name="gridLayout_4">
-      <item row="0" column="0">
-       <widget class="QLabel" name="inputProfLabel">
-        <property name="text">
-         <string>Input Profile</string>
-        </property>
-       </widget>
-      </item>
       <item row="0" column="1">
        <widget class="QComboBox" name="inputProfiles">
         <property name="sizePolicy">
@@ -250,6 +323,13 @@
       <item row="1" column="1">
        <widget class="QComboBox" name="renderIntent"/>
       </item>
+      <item row="0" column="0">
+       <widget class="QLabel" name="inputProfLabel">
+        <property name="text">
+         <string>Input Profile</string>
+        </property>
+       </widget>
+      </item>
      </layout>
     </widget>
    </item>
@@ -327,6 +407,9 @@
     </layout>
    </item>
    <item>
+    <layout class="QVBoxLayout" name="verticalLayout_2"/>
+   </item>
+   <item>
     <spacer name="verticalSpacer">
      <property name="orientation">
       <enum>Qt::Vertical</enum>
@@ -365,8 +448,6 @@
   <tabstop>imgDpiY</tabstop>
   <tabstop>keepImageWHRatioButton</tabstop>
   <tabstop>keepImageDPIRatioButton</tabstop>
-  <tabstop>frameScale</tabstop>
-  <tabstop>cbProportional</tabstop>
   <tabstop>inputProfiles</tabstop>
   <tabstop>renderIntent</tabstop>
   <tabstop>compressionMethod</tabstop>
alignImageUpdated.diff (8,950 bytes)   

TomZ

2015-10-28 07:39

reporter   ~0037020

Nice to see that someone is taking care of these old issues ;-)

I will test the next days!

ale

2015-10-28 23:26

manager   ~0037063

i have the feeling that they work correctly.

but i really would prefer to have buttons rather than drop downs...

i've added a mock up of it and a zip containing a first possible version of the icons for 1.5.1 (and i would let dezso or another designer create the definitive icons)

ale

2015-10-28 23:26

manager  

align-image.zip (2,125 bytes)

ale

2015-10-28 23:26

manager  

image-align-screenshot.png (77,867 bytes)   
image-align-screenshot.png (77,867 bytes)   

ale

2015-10-28 23:28

manager   ~0037064

btw, i still would prefer to have the buttons in the align and distribute dialog...

and when the user is in image edit mode the align and distribute dialog should show only one tab with the above attached buttons...

Dawoodalbadi

2015-10-29 03:14

reporter   ~0037071

Last edited: 2015-10-29 04:22

I agree that bottons will be very nice but I am zero in xml language
I will try to change it if I success I will update the patch
Thank you ale

Kunda

2015-10-29 04:13

updater   ~0037072

This feature is awesome!
I totally agree that these should be buttons and not dropdowns.
Lets make that happen!

Dawoodalbadi

2015-10-29 04:46

reporter   ~0037076

Last edited: 2015-10-29 04:47

I discuss the design with someone and he says that droplist is better than the bottons so I need to know what is the opinion of core developers , please informe me or make a note in mailling list to agreed about the final design before i change it

ale

2015-10-29 07:47

manager   ~0037084

i would be interested in kwnowing why the other person is preferring the drop down list.

my rational for the buttons:

i would use drop downs for selecting a type of alignement for the image. a property that is then stored in the frame properties.

but here we are just sending the frame content to one of the directions (top, bottom, left, right, center) and the user is then free to further move the content.

the button should not be in pushed down state afte they have been used. it's just an action, you're not setting a property.

it's exactly the same as one is doing in "windows > align and distribute" and it should IMO work in the same way.

i would even go further and say that this function should be in the "align and distribute" dialog. but we can further move it later, if we want to do so.


conerning the editing of the .ui file: i don't know this spcific file, but generally, it's better to modify them by using the designer part of qtcreator (the IDE relating to Qt).
directly editing the xml file is fine for small changes... but, as you noticed, can get pretty tedious...

ale

2015-10-29 10:45

manager   ~0037089

ps: if testers have the scribus github repository cloned you can try:

git fetch origin pull/32/head:pr-32
git checkout pr-32

to get the patch in a new local branch called pr-32 with the patch i've applied from dawoodalbadi.

Kunda

2015-10-29 15:54

updater   ~0037102

Dawood, found an issue with the patch:

1) Open an image frame

2a) Make the image frame larger than the image itself in the vertical plane
3a) Click Vertical > Middle OR Vertical > Bottom
4a) Click Vertical > None
Image has disaapeared (Click Vertical > 'Top' for image to return)

OR

2b) Make the image frame larger than the image itself in the horizontal plane
3b) Click Horizontal > Center OR Horizontal > Left
4b) Click Horizontal > None
Image doesn't dissappear but it doesn't respond correctly

Kunda

2015-10-29 15:58

updater   ~0037103

I also added a screencast of the overal feature in action so people can see it in action (not the bug I found)

Kunda

2015-10-29 15:58

updater  

image-align.gif (125,117 bytes)   
image-align.gif (125,117 bytes)   

Vladimir Savic

2015-10-29 16:57

reporter   ~0037106

My vote goes for including this functionality in Align&Distribute dialog.

cbradney

2015-10-30 06:23

administrator   ~0037118

Also, what scenario would someone have to not have the frame resized back down to the image size? I can think of some forced wrapping of text scenarios but I'm not sure this function even makes sense to include.

ale

2015-10-30 21:14

manager   ~0037127

mmm... i don't see why aligning the image to the frame should reset the image size.

i think that one of the guys shouting for this function was doing a catalog and he might have been working this way:

- resize the image until it fits horizontally
- align the image to the bottom of the frame

Dawoodalbadi

2015-10-31 05:54

reporter   ~0037131

I am willing to work in this patch again at the end of next week
So far i will change the control from menu to bottons and i will see the bug that kunda discover
If you have another problems tell me
Also if you think there is a need for other function like resize image tell me
And finally if you think this batch is not necessary or no need for it please inform me i will not wast my time on it

Thanks
Dawood

ale

2015-11-03 12:30

manager   ~0037178

craig, i thought again about what you wrote and i guess that: yes, somebody could achieve most tasks by resizing the frame to the image frame.

but not all of them.

as an example, "adjust frame to image" does not fit (correctly) when the image is not completely shown.

for others -- like in the catalog example -- it is more a faster way to get to the goal...

ale

2015-11-03 14:04

manager   ~0037183

@dawoodalbadi: if craig agrees with the the function being useful, please implement it as buttons in the properties palette.

as vlada notes, this function belongs in the align and distribute window (where, obviously, it would be implemented as buttons!) and we should move it there at some time (if possible before or during the transition to the new properties palette).

Kunda

2016-03-10 15:20

updater   ~0039108

When we get this implemented (crossing fingers) lets make sure to address 0005662 as well.

Issue History

Date Modified Username Field Change
2007-09-17 19:38 TomZ New Issue
2007-09-17 19:39 cbradney Relationship added related to 0006228
2007-09-17 21:33 christoph_s Status new => acknowledged
2008-02-05 18:51 christoph_s Relationship added related to 0005662
2014-02-09 03:57 jon.grossart Note Added: 0031288
2014-07-14 16:09 Kunda Target Version => 1.6 milestone
2014-09-19 08:28 ale Note Added: 0033756
2015-09-17 20:10 Kunda Category Graphics / Image Frames => Graphics/Img Frames
2015-09-17 20:11 Kunda Category Graphics/Img Frames => Graphics / Image Frames
2015-10-25 13:47 user5122 Tag Attached: HOST-Oman
2015-10-25 13:48 user5122 Tag Detached: HOST-Oman
2015-10-26 09:46 Dawoodalbadi Note Added: 0036943
2015-10-26 09:51 Dawoodalbadi Tag Attached: HOST-Oman
2015-10-27 21:54 Dawoodalbadi Note Added: 0036998
2015-10-27 21:55 Dawoodalbadi File Added: alignImage.diff
2015-10-27 22:35 cbradney Note Added: 0037001
2015-10-27 22:37 Kunda Patch => Yes
2015-10-27 22:59 Dawoodalbadi Note Added: 0037004
2015-10-27 23:18 cbradney Note Added: 0037006
2015-10-28 06:42 Dawoodalbadi Note Added: 0037019
2015-10-28 06:45 Dawoodalbadi File Added: alignImageUpdated.diff
2015-10-28 06:50 Dawoodalbadi Note Edited: 0037019
2015-10-28 07:39 TomZ Note Added: 0037020
2015-10-28 23:26 ale Note Added: 0037063
2015-10-28 23:26 ale File Added: align-image.zip
2015-10-28 23:26 ale File Added: image-align-screenshot.png
2015-10-28 23:28 ale Note Added: 0037064
2015-10-29 03:14 Dawoodalbadi Note Added: 0037071
2015-10-29 04:13 Kunda Note Added: 0037072
2015-10-29 04:22 Dawoodalbadi Note Edited: 0037071
2015-10-29 04:46 Dawoodalbadi Note Added: 0037076
2015-10-29 04:47 Dawoodalbadi Note Edited: 0037076
2015-10-29 07:47 ale Note Added: 0037084
2015-10-29 10:45 ale Note Added: 0037089
2015-10-29 15:54 Kunda Note Added: 0037102
2015-10-29 15:58 Kunda Note Added: 0037103
2015-10-29 15:58 Kunda File Added: image-align.gif
2015-10-29 16:57 Vladimir Savic Note Added: 0037106
2015-10-30 06:23 cbradney Note Added: 0037118
2015-10-30 21:14 ale Note Added: 0037127
2015-10-31 05:54 Dawoodalbadi Note Added: 0037131
2015-11-03 12:30 ale Note Added: 0037178
2015-11-03 14:04 ale Note Added: 0037183
2015-11-05 12:26 Kunda Sticky Issue No => Yes
2016-03-10 15:20 Kunda Note Added: 0039108
2024-01-02 19:22 cbradney Sticky Issue Yes => No