bugGNU Octave - Bugs: bug #62063, Manual position of legend changes...

 
 

bug #62063: Manual position of legend changes after print

Submitter:  George Apostolopoulos <gapost>
Submitted:  Wed 16 Feb 2022 11:59:12 AM UTC
   
 
Category:  Plotting Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * 7.0.90 Operating System:  * GNU/Linux
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 17 Feb 2022 09:36:14 PM UTC, comment #1: 

This behavior has already been fixed on the release candidate for version 7.1.  I used slightly modified test code:


x=[0:0.1:1];
plot(x,x.^2);

hl=legend('y(x)=x^2')

set(hl,'location','none')
set(hl,'position',[0.2 0.5 0.25 0.25])
% legend has the specified position
print -dpdfcrop tst_lgnd

get (hl, 'position')


Marking as Fixed and closing report.

(file #52878)

Rik <rik5>
Group administrator
Wed 16 Feb 2022 11:59:12 AM UTC, original submission:  

For a legend that has been positioned manually, the position is changed after a 'print' command.

Example code:


x=[0:0.1:1];
plot(x,x.^2);

hl=legend('y(x)=x^2')

set(hl,'location','none')
set(hl,'position',[0.2 0.5 0.25 0.25])
% legend has the specified position

print -dpdfcrop tst_lgnd
% legend position changed (more specifically: the width/height)
% on screen as well as in printed file


George Apostolopoulos <gapost>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #52878:  tst_leg_pos.m added by rik5 (199B - text/x-matlab)
file #52864:  tst_lgnd.pdf added by gapost (4KiB - application/pdf)
file #52863:  tst_lgnd_screen1.png added by gapost (18KiB - image/png)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Updated the item)
  • -email is unavailable- added by gapost (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-02-17 rik5 Attached File- Added tst_leg_pos.m, #52878
        StatusNone Fixed
        Open/ClosedOpen Closed
        Release6.2.0 7.0.90
    2022-02-16 gapost Attached File- Added tst_lgnd_screen1.png, #52863
        Attached File- Added tst_lgnd.pdf, #52864

    Back to the top

    Powered by Savane 3.13-4b48.
    Corresponding source code