Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6568023
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T14:24:24+00:00 2026-05-25T14:24:24+00:00

I have a UILabel on the screen, which is currently in portrait. However, I

  • 0

I have a UILabel on the screen, which is currently in portrait. However, I have a 3D scene rendered in the previous layer, which is presented landscape regardless. How would I be able to set the point of the label at 0,0; and have it be visible at 0,0; as if it was in landscape. I figure it would need to be rotated 90 degrees, and then have the axis inverted.

I’ve written some code, but it doesn’t work as I had hoped.

control.transform = CGAffineTransformRotate(CGAffineTransformIdentity, M_PI/2);

CGRect newFrame = CGRectMake(oldFrame.origin.x, oldFrame.origin.y, control.frame.size.width, control.frame.size.height);

newFrame.origin.y = 320 - (newFrame.origin.y - control.frame.size.width);

//invert the x and y axis
CGFloat x1 = newFrame.origin.y;
CGFloat y1 = newFrame.origin.x;
CGFloat w1 = newFrame.size.width;
CGFloat h1 = newFrame.size.height;

control.frame = CGRectMake(x1, y1, w1, h1);

I’m really confused about this!

Any help appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T14:24:25+00:00Added an answer on May 25, 2026 at 2:24 pm

    You should try not to mix portrait and landscape.
    Try using a UIViewController that only allows landscape; positioning the label would be much easier.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an UILabel that is centered in the screen. I want to place
I am an iOS development newbie. I have a settings screen which is a
I have a view that contains a UITableView and a UILabel which works perfectly
In my iPhone app I want to have a UILabel which counts down to
I have a UILabel to which I am attempting to apply a semi-transparent gradient
I have a UILabel and i have a uint16_t. How can I display the
I have three UILabel with different font and I want to put then on
I have a UILabel with space for two lines of text. Sometimes, when the
I have a UILabel that displays some chars. Like x, y or rpm. How
I have a UILabel with right-aligned text that may vary from between three to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.