Home
Blogs
Questions
Jobs
Monetize

Home

About Us

Blogs

Questions

Jobs

Monetize

Post Job

banner

Questions about qlist

Read more about qlist

python (65.2k questions)

javascript (44.3k questions)

reactjs (22.7k questions)

java (20.8k questions)

c# (17.4k questions)

html (16.3k questions)

r (13.7k questions)

android (13k questions)

Questions - qlist

Splitting QString on spaces and keeping the space in QList - best or 'canonical' way

As in the title, I would like to ask what is the best way to split a QString on spaces and - where relevant - keep the spaces as parts of the resulting QList elements. I'm interested in the most effic...
test-img

Bart M

c++

qt

split

qstring

qlist

Votes: 0

Answers: 1

Latest Answer

Consider myString.split(QRegularExpression("(?<= )") The regular expression says "an empty substring preceded by a space", using the positive look-behind syntax.
test-img

Igor Tandetnik

Qt 4.8 how to do get properties of a QPushButton placed in a QList&lt;QWidget *&gt;?

Do someone know a solution to do get properties of a QPushButton placed in a QList<QWidget *> ? .h QList<QWidget *> list; .cpp QPushButton *button = new QPushButton("Push", this...
test-img

zian

qt

qwidget

qpushbutton

qlist

Votes: 0

Answers: 1

Latest Answer

The problem is more to do with c++ and polymorphism in general rather than anything specific to Qt. The expression... list.at(0) returns a QWidget *. Hence the call... list.at(0)->text() fails ...
test-img

G.M.

Posts

Questions

Blogs

Jobs

The ultimate platform for coders and IT specialists

About

  • Company
  • Support

  • Platform

  • Terms & Conditions
  • Privacy statement
  • Cookie policy
  • Cookie option
  • OnlyCoders © 2025  |  All rights reserved