[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #65051] [Octave] print command does not render

From: Thomas
Subject: [Octave-bug-tracker] [bug #65051] [Octave] print command does not render plot correctly in pdf
Date: Tue, 19 Dec 2023 10:14:39 -0500 (EST)


                 Summary: [Octave] print command does not render plot
correctly in pdf
                   Group: GNU Octave
               Submitter: betdiscart
               Submitted: Tue 19 Dec 2023 03:14:37 PM UTC
                Category: Octave Function
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: None
                  Status: None
             Assigned to: None
         Originator Name: BETDiscart
        Originator Email: 
             Open/Closed: Open
                 Release: 8.4.0
         Discussion Lock: Any
        Operating System: Microsoft Windows
           Fixed Release: None
         Planned Release: None


Follow-up Comments:

Date: Tue 19 Dec 2023 03:14:37 PM UTC By: Thomas <betdiscart>

I'm trying to print a pdf plot in GNU Octave. I use Octave on a windows
machine. The graph is shown on the plot screen when executing the code.
Unfortunately the plot does not show the full graph when opening the plot in
the PDF document (see attachment).

Strangely enough the issue does not occur when I print the plot in png. 


Below i have made an example code to illustrate the problem. Does anyone know
how to resolve this issue?

close all
clear all

x = [0:0.001:1]';
y = zeros(size(x,1),10);

y(:,1) = arrayfun(@(x) x^(1/5),x);
y(:,2) = arrayfun(@(x) x^(1/4),x);
y(:,3) = arrayfun(@(x) x^(1/3),x);
y(:,4) = arrayfun(@(x) x^(1/2),x);
y(:,5) = arrayfun(@(x) x,x);
y(:,6) = arrayfun(@(x) x^2,x);
y(:,7) = arrayfun(@(x) x^3,x);
y(:,8) = arrayfun(@(x) x^4,x);
y(:,9) = arrayfun(@(x) x^5,x);
y(:,10) = arrayfun(@(x) x^6,x);

h = figure
hold on

for i = 1:10


set(gcf,'papert', '<custom>')
set(gcf,'papersize',[29.7 21])
set(gcf,'paperposition', [1 1 27.7 19])
set(gcf,'defaultaxesposition', [0.15, 0.15, 0.75, 0.75])
set (0,'defaultaxesfontsize', 11)

The same issue occurs when the command "saveas" is used. 

Thanks in advance



Reply to this item at:


Message sent via Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]