Welcome,
Guest
. Please
login
or
register
. Did you miss your
activation email?
French forum
Home
Help
Search
Login
Register
SFML community forums
»
Help
»
Window
»
RenderWindow 2.6.2 to 3.0.0
Print
Pages: [
1
]
Author
Topic: RenderWindow 2.6.2 to 3.0.0 (Read 259 times)
0 Members and 1 Guest are viewing this topic.
HeinzK
Jr. Member
Posts: 57
RenderWindow 2.6.2 to 3.0.0
«
on:
January 23, 2025, 04:16:18 pm »
if
(
(
k_sTitel.
GetLength
(
)
>
0
)
&&
(
k_sTitel
!
=
"None"
)
)
{
k_pWindow
-
>
create
(
sf
::
VideoMode
(
{
k_iDisplayX, k_iDisplayY
}
,
32
)
, k_sTitel.
GetcStr
(
)
, sf
::
Style
::
Default
, settings
)
;
}
else
{
k_pWindow
-
>
create
(
sf
::
VideoMode
(
{
k_iDisplayX, k_iDisplayY
}
,
32
)
, k_sTitel.
GetcStr
(
)
, sf
::
Style
::
None
, settings
)
;
}
.. sf::Style::Default and sf::Style::None .. what is wrong ?
«
Last Edit: January 23, 2025, 07:57:03 pm by eXpl0it3r
»
Logged
The trees, that obstruct the view on the forest, can be allowed to fall! (Die Bäume, die die Sicht auf einen Wald versperren, dürfen gefällt werden!)
eXpl0it3r
SFML Team
Hero Member
Posts: 11110
Re: RenderWindow 2.6.2 to 3.0.0
«
Reply #1 on:
January 23, 2025, 08:06:25 pm »
A new parameter has been introduced the
sf::State
, not to be confused with
sf::Style
.
See the
migration guide
or the
API documentation
.
As such your code would need to be:
k_pWindow
-
>
create
(
sf
::
VideoMode
(
{
k_iDisplayX, k_iDisplayY
}
,
32
)
, k_sTitel.
GetcStr
(
)
, sf
::
Style
::
Default
, sf
::
State
::
Windowed
, settings
)
;
k_pWindow
-
>
create
(
sf
::
VideoMode
(
{
k_iDisplayX, k_iDisplayY
}
,
32
)
, k_sTitel.
GetcStr
(
)
, sf
::
Style
::
None
, sf
::
State
::
Windowed
, settings
)
;
Logged
Official FAQ:
https://www.sfml-dev.org/faq/
Official Discord Server:
https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog:
https://duerrenberger.dev/blog/
HeinzK
Jr. Member
Posts: 57
Re: RenderWindow 2.6.2 to 3.0.0
«
Reply #2 on:
January 23, 2025, 08:25:07 pm »
.. understood!
.. but here the compiler reports no problem .. is the style missing here?:
k_pWindow->create(sf::VideoMode({k_iDisplayX, k_iDisplayY}, 32), k_sTitel.GetcStr(), sf::State::Fullscreen, settings);
Logged
The trees, that obstruct the view on the forest, can be allowed to fall! (Die Bäume, die die Sicht auf einen Wald versperren, dürfen gefällt werden!)
eXpl0it3r
SFML Team
Hero Member
Posts: 11110
Re: RenderWindow 2.6.2 to 3.0.0
«
Reply #3 on:
January 23, 2025, 09:36:53 pm »
Yes, there are two overloads, one for (..., style, state, ...) and one for (..., state, ...)
Logged
Official FAQ:
https://www.sfml-dev.org/faq/
Official Discord Server:
https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog:
https://duerrenberger.dev/blog/
Print
Pages: [
1
]
SFML community forums
»
Help
»
Window
»
RenderWindow 2.6.2 to 3.0.0